How do you add comments to java program?
Answers
Answered by
1
How do you comment in Java?
Use // text when you want to comment a single line of code. Use /* text */ when you want to comment multiple lines of code. Use /** documentation */ when you would want to add some info about the program that can be used for automatic generation of program documentation.
Use // text when you want to comment a single line of code. Use /* text */ when you want to comment multiple lines of code. Use /** documentation */ when you would want to add some info about the program that can be used for automatic generation of program documentation.
Answered by
0
You can add comments in Java by using these three symbols according to the use:
1. / / - / / this is a single line comments
2. / * * / - / * this is multiline comments * /
3. / * * * * / - / * * this is documentation comments * * /
Similar questions
Math,
7 months ago
Math,
7 months ago
Computer Science,
1 year ago
Political Science,
1 year ago
Science,
1 year ago