Look at this solution and this solution. For me both are same but for 1 it gives WA while AC for other. This is the ques. Why is it so?