The symbol used for a single-line comment in C is:
-
A
/* */
-
B
//
Correct answer
-
C
#
-
D
--
10 views
Explanation
// starts a single-line comment. /* */ is used for multi-line comments. Comments are ignored by the compiler and are used to explain code.
Reference
Asked in: Matric,FBISE
Doubts & discussion
Not sure why the answer is B? Ask here and get an explanation.
Ask a doubt about this MCQ