Hot Student Stories
Why scanf functions is not used to read a line of text?
1 answer
Add you answer
Wanna comment?
Please Sign In / Sign Up
Because it is not safe. Scanf puts the data in a buffer. It is not the size of check of the data can be larger than the buffer causing a buffer overflow with undefined (usually bad, but always undesirable) behavior.