Regarding the problem "Chef and Periodic Sequence"

@admin, Can you please let me know in the problem “Chef and Periodic Sequence”(Problem Code-PERIODIC) of SnackDown Round 1A,in which test cases,my solution went wrong? After the contest was finished,I copied one of the codes, which produced correct results and tested it with more than 1000 test cases against my code(I used an input generator and an output checker) and both the codes produced same results. Then I myself looked for any corner cases left behind but unfortunately I couldn’t find it. So, after spending 3-4 hours, I couldn’t find that test case in which my solution went wrong. Can you please provide me that test case?

Please provide a link to your solution.

try 1 -1 1 -1 1 -1 ans should be 2
and 2 -1 2 -1 2 -1 ans should be 1

and 3 -1 3 -1 3 -1 ans impossible

Answer of 2 -1 2 -1 2 -1 should be 2 @alphaxtitan_v1 (2 1 2 1 2 1)

Link to my solution is: @vipin1407

link to my solution is: @vipin1407