r/shittyprogramming • • Dec 05 '14

Recursion 101

Post image
316 Upvotes

73 comments sorted by

View all comments

10

u/davydog187 Dec 05 '14

These are obviously students who are learning to program, I think classifying this as shitty programming is a little harsh. Lets wait for them to have more experience before we judge their code as shit.

6

u/justabaguette Dec 05 '14

Normally I would agree, but in order to take this class you either have to take an even more basic programming course (which also covers recursion) or pass a placement test. The assumtion is students already know a thing or two about programming. The fact that this student can't understand why they are getting a stack overflow with such idiotic code at the end of the semester is just sad IMO.

3

u/davydog187 Dec 06 '14

Recursion is a fundamental computing concept that can be very hard to grasp for beginners. I don't think it's unreasonable for a beginner to have to have multiple semesters of exposure to recursion before they truly understand it. Especially those who have not studied higher level Mathis previously

2

u/justabaguette Dec 06 '14

Oh come on, if they knew even the slightest thing about recursion (which the student should) they should understand that this code is fundamentaly stupid.