C Preprocessor

Q1:
Which of the following are correct preprocessor directives in C?
1: #ifdef
2: #if
3: #elif
4: #undef

A 1, 2

B 4

C 1, 2, 4

D 1, 2, 3, 4

ANS:D - 1, 2, 3, 4

The macros #ifdef #if #elif are called conditional macros. The macro #undef undefine the previosly declared macro symbol. Hence all the given statements are macro preprocessor directives.



img not found
img

For help Students Orientation
Mcqs Questions

One stop destination for examination, preparation, recruitment, and more. Specially designed online test to solve all your preparation worries. Go wherever you want to and practice whenever you want, using the online test platform.