#t83. 有趣的跳跃
有趣的跳跃
Jolly Jumper
Problem Description
A sequence of length has a "jolly jump" if and only if the absolute differences of adjacent elements, when sorted, are exactly the integers from to . For example, 1 4 2 3 has a jolly jump, because the absolute differences are . Of course, any sequence containing only a single element always has a jolly jump. Write a program to determine whether a given sequence has a jolly jump.
Input Format
One line: the first number is , the length of the sequence, followed by integers, the elements of the sequence in order. The absolute value of each element does not exceed .
Output Format
One line. If the sequence has a jolly jump, output Jolly; otherwise output Not jolly.
Sample Input
4 1 4 2 3
Sample Output
Jolly