[quote=“syszee,post:1,topic:51511”]
You’re kind of answering your own question there
Think about it a bit more before starting to code!
Maybe do a 5 minute sketch of what the screen’ll look like, or visualise how the code’ll flow, maybe do a flowchart. Sketching out a class relationship diagram can be surprisingly helpful. Not saying always do those things, they’re just ways of helping yourself think about the program before actually starting to code it and (as you point out) more often than not getting in a mess.
Ideally then when you open Eclipse you’ll find the code flows cleanly and smoothly from your fingertips, quite naturally :point:
[quote=""]
[quote=""]
I say comment quite a lot, and do it as you code (not as an afterthought at the end, as if it was a homework assignment and comments would score a few extra marks!) Yes code with good comments is easier to read later, but just as important is that thinking about explaining the code to someone else makes you think about what the code’s actually doing. A lot of the time it’ll become clear some bit of code is dumb just from writing a comment to explain it. Other times you’ll realize you don’t actually quite understand what you’ve done yourself, which can’t be good 