MCQEasy1 mark
4
State whether the statement is True or False:
Multi line comments in Java start with /* and end with */.
Topic: Comments in Java
Previous-year question practice database
Try it
Pick an option and check your answer. The full worked answer is below either way.
Answer
Exam answer
(a) True.
Explanation
True. Java has three comment forms: // for a single line, /* ... */ for several lines, and /** ... */ for documentation comments read by the javadoc tool. Comments are ignored entirely by the compiler, so they cost nothing at run time and should be used freely to explain the logic — which is what the "variable description / mnemonic codes" instruction in Section B is asking for.
In words
True.
More from Revision Tour I
The full form of JVM is:2026Which of the following occupies 2 bytes of storage?2026In a statement c = c + (x * d + e); which variable is an accumulator?2026Assertion (A): The result of the Java expression 3 + 7/2 is 6.
Reason (R): According to the hierarchy of operators in Java, addition is done first followed by division.2026Evaluate the Java expression:
x = a * b % (++c) + (++a) + (--b);
if a = 7, b = 8, c = 22026System.out.println('Z' + 32); will display:2025