Beware, it may not always be possible to travel from city 1 to city n . The first line of input will be n , the number of cities. The second line will be n integers showing the delay for city . During the trip, delays apply to cities 1 and n as well as all intermediate cities. You may also travel from city y to city x with the same delay.
All delays are integers.
Your goal is to find the quickest time to get from city 1 to city n . You do not have to visit all cities. You may assume all delays within a city or between cities will be less than or equal to 100, and the maximum number of cities is 100. The output consists of two lines. If there are multiple shortest paths, you may output any such path.