C | Macro & Preprocessor | Question 14
#include <stdio.h> #define get(s) #s int main() { char str[] = get(GeeksQuiz); printf("%s", str); return 0; } |
chevron_right
filter_none
(A) Compiler Error
(B) #GeeksQuiz
(C) GeeksQuiz
(D) GGeeksQuiz
Answer: (C)
Explanation: The preprocessing operator ‘#’ is used to convert a string argument into a string constant.
Quiz of this Question
Recommended Posts:
- C | Macro & Preprocessor | Question 2
- C | Macro & Preprocessor | Question 9
- C | Macro & Preprocessor | Question 8
- C | Macro & Preprocessor | Question 7
- C | Macro & Preprocessor | Question 6
- C | Macro & Preprocessor | Question 5
- C | Macro & Preprocessor | Question 4
- C | Macro & Preprocessor | Question 14
- C | Macro & Preprocessor | Question 1
- C | Macro & Preprocessor | Question 13
- C | Macro & Preprocessor | Question 15
- C | Macro & Preprocessor | Question 11
- C | Macro & Preprocessor | Question 12
- C | Macro & Preprocessor | Question 10
- The OFFSETOF() macro



