Storage Classes MCQ Questions and Answers

Home | C Language | Storage Classes

Storage Classes MCQs Questions - Student! here available c language mcq on storage classes, you can learn and test online questions with answers.

Page: 1/4

1) What will be the output of the following C code?

 #include <stdio.h>
void main()
{
m();
printf("%d", x);
}
int x;
void m()
{
x = 4;
}

2) An external variable is one:

3) What will be the output of the following C code?

 #include <stdio.h>
int x;
void main()
{
printf("%d", x);
}

4) What will be the output of the following C code?

 #include <stdio.h>
int x = 5;
void main()
{
int x = 3;
printf("%d", x);
{
x = 4;
}
printf("%d", x);
}

5) What will be the output of the following C code?

 #include <stdio.h>
int x = 5;
void main()
{
int x = 3;
printf("%d", x);
{
int x = 4;
}
printf("%d", x);
}

6) Functions in C are always _________

7) Global variables are ____________

8) Which of the following is an external variable in the following C code?

 #include <stdio.h>
int func (int a)
{
int b;
return b;
}
int main()
{
int c;
func (c);
}
int d;

9) What will be the output of the following C code?

 #include <stdio.h>
int main()
{
printf("%d", d++);
}
int d = 10;

10) What will be the output of the following C code?

 #include <stdio.h>
double var = 8;
int main()
{
int var = 5;
printf("%d", var);
}