Which of the following is not possible statically in C language?
a) Static allocation of array size
b) Static allocation of linked list
c) Static allocation of structure members
d) Static allocation of global variables
Answer:
b) Static allocation of linked list
Explanation:
In C, static allocation is possible for arrays, structure members, and global variables, but not for linked lists. Linked lists require dynamic memory allocation because the size of the list can change during runtime. Static allocation is not flexible enough to handle the dynamic nature of linked lists.
Understanding the limitations of static allocation is important for correctly managing memory and data structures in C programming.