Vidyalelo
C Programming · Q166

File Input Output

Programming · C Programming · question 166

Q166

What will be the output of the following C code? #include int main() short int i; scanf("%h*d", &i); printf("%hd", i); return 0;

A.
Compilation error
Answer
B.
Undefined behavior
C.
Somegarbage value
D.
Depends on the standard.

Answer: Option A

Solution

Answer: Option A
No explanation is given for this question Let's Discuss on Board