- Leave no to other developers.
- Describe what your code does.
- Leave notes to yourself for the future.
- Single-line Comment
- Multi-line Comment
Single Line Comments
Single line comments start with
// ( two forward slashes).
This example uses a single-line comment before each line of code:
Multi-line comments start with
/* and end with
Any text between
/* This is a multi-line comment */ /* This is another multi-line comment */