Open In App

C | Misc | Question 1

In the C language (GATE CS 2002)

(A) At most one activation record exists between the current activation record and the activation record for the main
(B) The number of activation records between the current activation record and the activation record for the main depends on the actual function calling sequence.
(C) The visibility of global variables depends on the actual function calling sequence.
(D) Recursion requires the activation record for the recursive function to be saved on a different stack before the recursive function can be called.

Answer: (B)
Explanation: a) –> There is no such restriction in C language
b) –> True
c) –> False. In C, variables are statically scoped, not dynamically.
c) –> False. The activation records are stored on the same stack.

Article Tags :