There are ā€˜nā€™ ticket windows in the railway station, ith window has a[i] tickets available. Price of a ticket is equal to the number of tickets remaining in