Company: capital one IITK
Difficulty: medium
Gaming Marathon Problem Description Alex wants to complete all the levels of a video game in the shortest time possible. Each level requires a specific number of minutes to finish, with levels taking consecutive amounts of time. Alex can only play during designated gaming sessions throughout the day. Each day consists of a fixed number of minutes, and there are multiple gaming sessions available during each day. The challenge is to determine whether Alex can finish the entire game and, if possible, calculate the minimum time needed to complete all levels. Complete the solve function. This function takes the following 5 parameters and returns the answer. Parameters: n : Represents the number of breaks m : Represents the number of game levels t : Represents the time to complete each level k : Represents the length of each day B : Represents the list of pairs with values l and r the range of break Input format: The first line contains T , which represents the number of test cases. For eac