Hey, mate I wanted to know what wrong's with my submission ?

https://www.codechef.com/viewsolution/55915780

Consider the test input:

1
7 5 7
1 Like