Here is link to my code. I have no idea, why I am getting WA? The code looks fine to me. Could someone please point out my mistake?
Your code doesn’t even pass sample test cases.
Oh, I got it why It is not working. I did not consider the whitespace in the input Thanks to pointed out
Your code doesn’t even pass sample test cases
otherwise, I would have kept wondering what is wrong.
Updated solution, Still getting WA
6 11 22 33 44 55 66