r/programming • • May 08 '15

Five programming problems every Software Engineer should be able to solve in less than 1 hour

https://blog.svpino.com/2015/05/07/five-programming-problems-every-software-engineer-should-be-able-to-solve-in-less-than-1-hour
2.5k Upvotes

2.1k comments sorted by

View all comments

Show parent comments

4

u/[deleted] May 08 '15

while the 4th has a fairly simple general solution after a moment's thought

I wonder how many people are saying this because they say the simple solution, and how many are saying this because they incorrectly saw the wrong solution...

4

u/pernicat May 08 '15

There seems to be a lot of "number 4 is really trivial, here is my solution" then someone points out a counter example. Either that or their solution ends up being O( n2 ) after accounting for all the edge cases.