Probably the only ones that need explaining are the logical operators . A logical operator extends the action of if-else statements. We'll discuss logical operators more when we go over if-else statements. Use comments abundantly so that someone reading your COG later has a clear guide to the COGs functions. Another programmer might be able to trace through your code and figure out how the COG works, but comments speed up the process.
Comments extend to the end of the line.
Anything following a comment is disregarded by Jedi Knight. How you choose to add your comments is up to you. Using comments for things like the example above is redundant, as anyone can tell that x is being incremented by 1. I suggest using comments only when they help explain what is going on in the code. One of the most common C commands, the if statement can be found in every programming language.