Update: It was just a matter of Capitalization of “Yes” and “No” as part of the answer. Thank you for pointing it out.
Can someone please tell me what’s wrong with my solution for the lunchtime contest:
Update: It was just a matter of Capitalization of “Yes” and “No” as part of the answer. Thank you for pointing it out.
Can someone please tell me what’s wrong with my solution for the lunchtime contest:
1 obvious thing that I first notice is that you have printed Yes instead of YES and No instead of NO, that will cause WA even if answer is correct
the cases of “Yes” and “No” is the only issue. Rest all seems fine.
Can someone please help me understand what am I missing in my solution.
https://www.codechef.com/viewsolution/34798987
Thanks a lot for that reply!! It’s the first time I’ve made that mistake. Seems really foolish.
I will be more careful next time
There seems to be logical error(not too familiar with Python). But think of it this way: What are the conditions for which the answer will be NO. Let freq be an array storing the frequency of A_i for all i. Following two conditions will be case of NO
Apart from these two cases, the answer will be YES