3 ms·
The worst part of Hacker Rank is that it takes arguments as STDIN, forcing you to to a "read from STDIN" ceremony before actually getting to the problem.
by sotojuan 10y ago
The worst part of Hacker Rank is that it takes arguments as STDIN, forcing you to to a "read from STDIN" ceremony before actually getting to the problem.
- natdempk 10y agoI could see why that might be annoying, but it forces the coder to make choices about their data structure and makes it easier for hacker rank to support many languages.
- akerl_ 10y agoIf reading from STDIN is something that's considered a "ceremony", I'm already concerned about the rest of the code. STDIN is one of the most common input methods I use for most of the commands I interact with on a daily basis. It would be like discovering that somebody found "logging errors to STDERR" to be a "ceremony"
- deleted 10y ago[deleted]
- coredog64 10y agoThe days of Perl CGI are a distant memory. More than that, it is a distraction. I'd be happier with the use of a parameterized test framework that lets you get to the point much more quickly.
- peruvian 10y agoIn real life, I agree. But if I'm trying to solve an array sorting problem, why can't they just give me an array? LeetCode does it and it works fine. I get to focus on how to sort the array. The other commenter (natdempk) makes some good points though.
- jakobegger 10y agoIf you work with a modern framework, chances are high you'll never actually read from STDIN. For example, I have no idea how I'd read from standard input in ObjC or Swift.
- twic 10y agoIn most of the problems i've done, there's boilerplate code to read from standard input supplied as part of the problem. You just have to implement the algorithm. In the problems where it's not, yeah, it's annoying. But it's also the same one or two lines every time, so it's not a big deal.