Where does the uninitialized data gets stored in memory?
Answer: C
Correct answer: BSS- Block started by symbol
The BSS holds objects with static storage duration that have no explicit initialiser, and which are therefore zero-initialised before the program starts.
Keeping them separate saves space in the executable: the file need only record how many bytes to reserve, and the loader clears them, rather than storing a long run of zeros on disk. Initialised globals go in the data segment proper, where their values must actually be stored, and the code segment holds the instructions.
Please log in or register to report this question.