QP School

Full Version: Nested multi-line comments in C
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Example:

/*
    This is the outer comment.
    /* This is a nested comment. */
    It is ignored as well.
*/

Explanation:

C allows nesting of multi-line comments.
In this example, an inner multi-line comment /* This is a nested comment. */ is placed within the outer comment.
The compiler ignores both the outer and inner comments.