Coding Horror by Jeff Atwood made me cry today. I wanted to laugh but it was so painful all I could do is shake my head and cry. Two days ago he made a very good post asking "Why can’t programmers.. Program?" He referenced Imran on Tech who uses a simple problem to figure out if his prospective candidates can code. Imran also has good tastes in WordPress themes. One of Imran’s test questions:
Write a program that prints the numbers from 1 to 100. But for multiples of three print “Fizz†instead of the number and for the multiples of five print “Buzzâ€. For numbers which are multiples of both three and five print “FizzBuzzâ€. [Source]
The result was programming types completely missing the point of his post. The tears come in the comments. The first commenter rushed to get his solution to the problem before anyone else. Naturally, many other commenters followed with solutions in different languages or varying degrees of optimization. Why did I cry? Almost every solution has an error!
I also like the debate between the academics and the professionals about recursion. And yes, my view is that recursion belongs in academia and rarely (if ever) in commercial software.
Sadly, it appears that indeed programmers cannot program and, better yet, they cannot even read for comprehension!
I remember these exercises in basic (not BASIC, but basic – I’m not that old) programming classes back in college. They were fun, actually, once you got past the, “Whuhh…??” factor.