Warning: implode(): Invalid arguments passed in /www/wwwroot/jobquiz.info/mdiscuss.php on line 336 There exists a way to prevent the same file from getting #included twice in the same program. ?->(Show Answer!)
1. There exists a way to prevent the same file from getting #included twice in the same program.
Ask Your Doubts Here
Comments
By: guest on 01 Jun 2017 06.00 pm
True, We can prevent the same file from getting included again by using a preprocessor directive called #ifndef (short for "if not defined") to determine whether we've already defined a preprocessor symbol called XSTRING_H. If we have already defined this symbol, the compiler will ignore the rest of the file until it sees a #endif (which in this case is at the end of the file). #ifndef XSTRING_H #define XSTRING_H defines the same preprocessor symbol, Finally, the last line of the file, #endif