We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
Yeah, it makes sense in the real world to check your inputs against the constraints given, you should throw an error in your code if someone else's code isn't functioning properly and that'll cause an error in your code. On the other hand, code that's as robust as possible and "just works" virtually no matter what without using too much memory has its own place in the scheme of things.
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
PRNG Sequence Guessing
You are viewing a single comment's thread. Return to all comments →
Yeah, it makes sense in the real world to check your inputs against the constraints given, you should throw an error in your code if someone else's code isn't functioning properly and that'll cause an error in your code. On the other hand, code that's as robust as possible and "just works" virtually no matter what without using too much memory has its own place in the scheme of things.