Programming MCQS - QUESTION DETAILS

How do you declare a global variable in C?
A. global var;
B. int global;
C. extern int global;
D. static global;

'extern' is used to declare a global variable in C.

Similar Questions

What is the purpose of the 'break' statement in a switch statement?






What is the purpose of the 'strchr' function in C?






How do you create an object of a class in Java?






What is the output of printf("%d", 5 + 3 * 2);?






Which method is used to read data from the keyboard in Java?






How do you define a macro in C?






What is the purpose of the 'typedef' keyword in C?






Which function is used to read a character from the standard input in C?






In C, how do you declare a constant?






What does the 'printf' function do in C?