Participate in exhilarating programming contests, solve unique algorithm and data structure challenges and be a part of an awesome community.
Given N numbers determine if they are in ascending order.
The first line of the input will contain N (0 < N < 100).
The following line will contain N integers, each between 1 and 1000.
Print “Yes” if the numbers were in ascending order, otherwise “No”.
Input | Output |
---|---|
3 1 2 3 | Yes |
Login to submit