#K77802. Determine Sequence Type
Determine Sequence Type
Determine Sequence Type
You are given an array of positive integers. Your task is to determine whether the given sequence is strictly increasing, strictly decreasing, or neither.
A sequence is strictly increasing if for every index \(i\) (with \(1 \leq i \lt n\)), it holds that \(a_i < a_{i+1}\). Similarly, it is strictly decreasing if for every index \(i\), \(a_i > a_{i+1}\). If neither condition is satisfied, then the sequence is classified as Neither.
Note: A sequence with a single element is considered strictly increasing.
inputFormat
The first line of input contains an integer \(n\) (\(1 \leq n \leq 10^5\)), which is the number of elements in the array. The second line contains \(n\) space-separated positive integers representing the sequence.
outputFormat
Output a single line containing one of the following strings: Increasing, Decreasing, or Neither, depending on the order of the sequence.
## sample5
1 2 3 4 5
Increasing