F. Mountain Heights
time limit per test
2.5 seconds
memory limit per test
1024 megabytes
input
standard input
output
standard output
Examples
Input
4 3
3 7 2
Output
1
1 
Input
8 4
7 5 1 4
Output
2
1 3