Commenting Lines of Code
Comments within a program's code are extremely useful for both the writer them self or for other compiler users examining and using the code in their programs. Comments allow the user to indicate what a procedure or subroutine does and to indicate what the procedure requires as inputs and what it produces as outputs etc...
Comments are also useful, almost mandatory, at the beginning of a program to indicate what the program does and what compiler version it was written in, and the name, and other relevant information, concerning the actual writer of the code etc...
As you can, probably, gather from the above statements, I am a very strong advocate of code comments so that other users can understand what the piece of code I have written actually does, and they are important so I can see what a piece of code does, many months, or even years, after it has been written.
An apostrophe character ' can comment out a single line of code, comment out text that follows a line of code.:
HRsoutLn "Hello World" ' A comment to indicate what the line of code is doing
If a block of code or text needs to be commented out, the opening characters (* are used and then the closing characters *). For Example:
(*
This is commented text that
is on as many lines as required
*)
or:
(*This is commented text that
is on as many lines as required*)
Within the IDE, the commented lines can have their colour and format changed so they stand out more within the code. My preferred colour and format is Italicised Dark Blue.
