View Single Post
  #29   Spotlight this post!  
Unread 26-02-2015, 01:12
King Nerd III's Avatar
King Nerd III King Nerd III is offline
Chief Programmer/Head of Autonomous
AKA: Isaac
FRC #1410 (The Kraken)
Team Role: Programmer
 
Join Date: Jan 2014
Rookie Year: 2014
Location: Denver, CO
Posts: 116
King Nerd III is an unknown quantity at this point
Re: Quotes from the Chief Engineer and I

Quote:
Originally Posted by wireties View Post
Express your solution in a diagram or notation of some sort (UML or simple flow diagrams and so on) first. When you start coding, comment first and fill in the code afterwards. If your style is good, the code is readable and the comments explain the algorithm. Little else is really necessary no matter the audience.
I've started to draw out the code before hand, but never thought of the comment first. I think I'll stick to a bunch of comments for examples, though, at least for the first few programs with teaching kids. So far it's been really helpful to be able to say here's a program to look at, the comments should explain what's happening, as usually in the first few weeks we have too many programmers at different levels to teach all at once.