All functions return some value. Does it mean that even printf and scanf which are functions in C return some value? If so what is the value returned by these functions.
All functions return some value. Does it mean that even printf and scanf which are functions in C return some value? If so what is the value returned by these functions.
Yes. As all functions return value so are these functions. I am not aware about scanf but printf returns the number of characters printed by the printf function. Hope we get to know about the return value of more functions in this discussion.
printf returns the number of characters that it prints, whereas scanf returns the number of format specifiers being passed to it in the format string.
Correct me if i am wrong...