Ah of course not, make the program slower no?
thx for helping!
Well, on a small practice piece like this it doesn't make enough difference to sniff at but in larger projects where you are doing a lot of repetative stuff it can (and does) make a very noticeable difference.
But there is considerable merrit in forming good habits early.
When I program I work in several phases...
1) Thinking about what I need to do...
2) Writing up a step by step plan...
3) Writing the code, most often just getting it to work *at all*.
4) Testing and improving the code to get the biggest bang for the buck from it.
5) Hoping I never have to do that again... LOL.
There are a couple of ground level "rules" you can adopt to help you along...
1) "Compiles" does not mean "Works".
2) Comments are our friends.
3) Never create a variable you don't absolutely need.
4) Never be afraid to look stuff up (i.e. wear out your F1 key!)
5) Treat all compiler messages as issues to be fixed.
6) When being your most clever, ask: "If I come back to this in 5 years, will I still be able to follow it?"