What values does uninitialized automatic variables contain?

What values does uninitialized automatic variables contain?
A. Null value
B. Void value
C. Undefined/Garbage
D. Zero value
 
Answer: c
Explanation: The automatic variable which are not initialized, contain garbage value. If we just declare a variable and try to print its value, the result is some unknown value. The value is garbage as that was not expected value.
 

Tìm kiếm

Back
Top