What does the following C statement mean? scanf ("%4s', str);
What does the following C statement mean?
scanf ("%4s', str);
Show answerHide answer
Correct answer: (B) Read maximum 4 characters from console
Explanation
A width in %4s limits input: scanf reads at most 4 non-whitespace characters into str. It may read fewer if whitespace comes first.