BTAR - Editorial

why is this not working

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

Hey @taran_1407 and @likecs can you please tell me about the difference between the following two codes as one got WA while the other got AC. The only difference in the two codes is that- in one i have used only “if” statements to compare numbers having modulo 1 and 3(WA) while in the other i used “nested if else”(AC).
Please help me as i got WA during contest and would not want this to happen again.
link text
(WA)

link text
(AC)