Syntax highlighting makes it more clear (comments in green):
1 2 3 4 5 6
// this is a comment. Also a comment because same line
New line, so not a comment
/* this is a comment
new line, but still a comment
still comment */ not a comment anymore because we hit a */ symbol
How many words or letters can placed on a single line, let's say in Dev-C++, when writing the code? If I have enabled "wrap to window" or "wrap to ruler" in the windows' wordpad, then when I read the end of the window or ruler, the cursor automatically shifts to the next line. But if no "wrap" is enabled then I would have to scroll left and right to see the text. Now suppose I have a long "cout" or "if" statement to make, then how can I do the wrapping? Is it allowed in C++. Please don't forget that I'm a beginner.
@OP: I personally don't use // except to diagnose something or insert a definite one-liner. /* .. */ is so good that you can even: cout << "Have " << /*comments inside*/ "a line of code." << endl;