GATE CSE C Programming Practice Test – Function & Storage Class | Set 1

Questions 11-15 of 100

Your score 0/100 0 answered
Correct 0 Incorrect 0 Unanswered 100 Accuracy 0%

Question 11

MCQ · Single Correct 2 mark

What is the effect of declaring a function parameter as 'register int count' in C?

Answers for question 11

Question 12

MCQ · Single Correct 1 mark

Which memory segment stores uninitialized global and static variables in C?

Answers for question 12

Question 13

MCQ · Single Correct 2 mark

What is the scope and linkage of a top-level global variable declared as 'static int var = 13;' in a C source file?

Answers for question 13

Question 14

MCQ · Single Correct 1 mark

What is the output of the following C code?

C
#include <stdio.h>
int x = 14;
int main(void) {
    int x = 24;
    {
        int x = 34;
        printf("%d ", x);
    }
    printf("%d", x);
    return 0;
}
Answers for question 14

Question 15

MCQ · Single Correct 2 mark

Consider a function returning a value: 'int calc(int a) { static int s = 15; s += a; return s; }'. What is returned by calling calc(5) twice consecutively?

Answers for question 15
Scroll to Top