C Programming :: Functions - Discussion
Home > C Programming > Functions > MCQs Questions Discussion
2 / 53
What is the output of the following problem ?
#include<stdio.h>
int main()
{
int j;
for(j=0;j<3;j++)
foo();
return 0;
}
foo() {
static int i = 10;
i+=10;
printf("%d",i);
}
#include<stdio.h>
int main()
{
int j;
for(j=0;j<3;j++)
foo();
return 0;
}
foo() {
static int i = 10;
i+=10;
printf("%d",i);
}
A20 20 20
B20 30 40
C10 10 10
DNone of these
Answer: Option (Login/Signup)
Show Explanation
Asked In ::
No Discussion on this question yet!