Company: Ibm_2dec
Difficulty: medium
Signal Tower Calibration Problem Description In a tech park, N signal towers are placed in a straight line, numbered from 0 to N-1 . An engineer is testing these towers for M rounds. In each round: The engineer chooses one tower by its position. Let's call this the reference tower. That reference tower gets a signal strength of 0 . Towers on the right of it get signal strengths of 1, 2, 3, ... as you move to the right. Towers on the left of it also get signal strengths of 1, 2, 3, ... as you move to the left. For example, if there are 6 towers and the chosen position is 3, then the signal levels for that round will be: [3, 2, 1, 0, 1, 2] . After all the rounds are done, each tower remembers the highest signal strength it got in any round. Your task is to print that final list. Input Format The first line contains an integer N , the number of towers. The second line contains an integer M , the number of rounds. Each of the next M lines contains an integer representing the position selec