This sub should really be enforcing proper code formatting

I was a programming tutor in college for a while, and the majority of code that people brought in was formatted horribly.

We used Java, so things were a little different than with Python, but you'd see really weird (if any) indentation; large sections of whitespace and large sections of code with no whitespace; extremely deep nesting of conditionals, switches, and loops.

As far as structure, generally they'

I genuinely think that they don't have a sense that it looks bad.

When the only code they're exposed to is nicely formatted in-class or online, and the code that they write makes sense to them (while they're working on it, anyway), they won't really realize what's missing with their poorly structured programs. They also tend to think all their struggles with learning and debugging come from the subject being to difficult; really they're being hindered by their formatting. They think that's what programming is.

There's no baseline for them to compare against unless they're forced to read and understand other peoples' bad code in a collaborative environment.

/r/learnpython Thread Parent