0
In 'Code Coach' section, why are there 3 test cases (out of 5) always hidden?
While I was solving the 'Argentina' challenge, my code was successful for the 1-4 test cases, but failed the 5th test case. Since it is hidden I can't understand what is the error or what do I need to change. I have changed my code twice but the result is the same as above. PLEASE HELP!
3 Réponses
+ 3
If all were visible you could "hardcode" every scenario into the code. You could just use some ifs for every test case and print the expected result. Sry, but I can't help you with this. Maybe you can figure out where your code might fail in certain cases.
+ 2
Even if you create any real time application then also you can never know what exactly the user will enter. It is expected that your code should run perfectly for all correct inputs. If it's failing at some point means either you overlooked some edge cases or your algorithm is not perfect.
+ 1
If you share your code with which you are getting trouble, then some one help you by checking it and reply errors, may suggest changes you need...
Or else use search bar for similar question and see how they solved...