C Preprocessor on C related Questions and Answers

Question 1 : In the directive, #pragma pack(n), which of the following is not a valid value of n?
1. 1
2. 2
3. 3
4. 4
View Answer   Discuss with Members

Question 2 : In the directive #pragma pack(n), if the value of 'n' is given to be 5, then what happens?
1. Error
2. Warning but no error
3. Executes the pragma statement
4. Ignores the pragma statement and executes the program
View Answer   Discuss with Members

Question 3 : The preprocessor directive used to give additional information to the compiler, beyond which is conveyed in the language _____________
1. #include
2. #define
3. #pragma
4. #elif
View Answer   Discuss with Members

Question 4 : The function of __attribute__((packed)); can also be performed using _________
1. #pragma pack(1);
2. #pragma pack(2);
3. #pragma pack(4);
4. #pragma pack(8);
View Answer   Discuss with Members

Question 5 : Which of the following attributes is used to specify that the minimum required memory to be used to represent the types?
1. packed
2. aligned
3. unused
4. deprecated
View Answer   Discuss with Members

Question 7 : #pragma GCC poison should be followed by a list of identifiers that are _________
1. even in number
2. odd in number
3. valid
4. invalid
View Answer   Discuss with Members

Question 8 : Which of the following is a stringizing operator?
1. < >
2. #
3. %
4. ##
View Answer   Discuss with Members

Question 9 : Which of the following operators is used to concatenate two strings without space?
1. #
2. < >
3. **
4. ##
View Answer   Discuss with Members

Question 10 : The pragma ___________________ is used to remove an identifier completely from a program.
1. GNU piston
2. GCC poison
3. GNU poison
4. GCC piston
View Answer   Discuss with Members


View 1 - 10 of 17 Questions

* Be the First to Post a Comment.

Submit comment :


Captcha Image
Reload

Ask Question

Captcha Image
Reload

Note : Name and Email never shown.





Subscribe


Become a part of EducationForever. Subscribe to our FREE Newsletter