Question:What will be output of the following c program?#include<stdio.h> static num=5; int num; extern int num; int main(){ printf("%d",num); return 0; }
#include<stdio.h> static num=5; int num; extern int num; int main(){ printf("%d",num); return 0; }
A 5 B 10 C 0 D Compilation error E None of these
+ AnswerA
+ ExplanationTwo or more global variables can have same name but we can initialize only one of them.
+ Report