kushanzaveri loves sequences. However, he finds that the grade 11 categorizations of sequences are too easy.
Sequences have 4 categories:
- Arithmetic: Consecutive terms have a constant difference.
- Geometric: Consecutive terms have a constant factor (multiple)
- Both: Both an arithmetic and geometric sequence
- Random: Not an arithmetic nor geometric sequence
Categorizing a sequence is an easy P1 of a contest
Input will initiate with a single integer ~N~ ~(3 \le N \le 10)~, the number of elements in the sequence.
The second line will contain ~N~ integers, ~E_n~, the ~n~th element. ~(-1000 \le E_n \le 1000)~.
random depending on the type of sequence.
Sample Input 1
4 1 3 9 27
Sample Output 1
Sample Input 2
5 -1 2 -3 4 -5
Sample Output 2