r/programming • • May 09 '15

"Real programmers can do these problems easily"; author posts invalid solution to #4

https://blog.svpino.com/2015/05/08/solution-to-problem-4
3.1k Upvotes

1.3k comments sorted by

View all comments

Show parent comments

-22

u/UlyssesSKrunk May 09 '15

They do though.

1-3 just show that the candidate is not a complete moron and is capable of programming.

4-5 are only solvable if the candidate is actually at least somewhat intelligent and is able to think about things a bit more deeply.

16

u/[deleted] May 09 '15

actually at least somewhat intelligent

Damn this whole blog post and related discussion has made me realize I'm an idiot

15

u/dangfrick May 09 '15

No man, I guarantee the guy who wrote that shitty blog spent way more than an hour on 4 and 5. As would most people.

10

u/joggle1 May 09 '15 edited May 09 '15

Unless you never consider brute force as an option, I'm not sure how problem five was difficult. I can only imagine that it was difficult in that most programming challenges have an elegant solution and we're only looking for elegant solutions (which would just cause you to spin your wheels in this case). If the challenge way to come up with the most efficient was of solving the fifth problem, then I'd agree it was difficult.

I'd feel dirty giving a brute force answer at an interview, but it would be better than nothing and I could probably come up with some optimizations after taking my first try at the solution.

→ More replies (8)