Swiggy Interview Question

Sort the array, print 2nd largest number in array