Comment characters in C language are generally divided into two types. One starts with "/*", adds the comment content in the middle, and ends with "*/" paragraph comment. Anything between "/*" and "*/" is a comment.
The other is a single-line comment that starts with "//" and is followed by the comment content. Anything after "//" is a comment.
When the program is compiled, the comment content will not be processed in any way. Comments can generally appear anywhere in a program. Comments are used to prompt or explain the function of the program to the user or programmer.
The comment character in C language is a string starting with "/*" and ending with "*/". Anything between "/*" and "*/" is a comment. When the program is compiled, comments are not processed in any way. Comments can appear anywhere in the program. Comments are used to prompt or explain the meaning of a program to the user. In the debugging program, statements that are not used temporarily can also be enclosed in comments so that the translation will be skipped without processing. The comments will be removed after debugging is completed.
In the C language source program, you can use "/*....*/" as the comment character, or you can use "//" as the comment character. Among them, "/*....*/" is a multi-line comment character, and "//" is a single-line comment character. In addition, in C language C90, "//" can also be used as a comment character.
Recommended tutorial: c language tutorial
The above is the detailed content of What are the comment symbols in c language. For more information, please follow other related articles on the PHP Chinese website!