Let’s face it. This problem is here just to spite you off. So, I will not beat around the bush. You …
Click here to read the complete problem statement.
If you need help solving this problem, mention your approach and ask specific questions. Please avoid sharing your code and asking the Community to figure out “what’s wrong”.
And, I loved the fact that some people figured out such interesting ways of solving this problem.
I mean, it is easy to go for the most obvious or naive way of solving this and that is perfectly fine. But some people clearly figured out smarter ways to solve it. These ways are even easier to code and you are less likely to make mistakes in them.