What is printf() and scanf() in c?
There is a various predefined function in c language. print() and scanf() are predefined functions in c which are predefined in the studio.h header file.
They are used to perform input-output operations in c
print()
syntax:
printf(format_specifier, variable_name);
- print() is a predefined function in c used to print output on the screen.
- It is predefined in standard input output header file.
- print() function is case sensitive means that if we write it in uppercase then we get an error at the time of compilation.
scanf()
syntax:
scanf(format_specifier, variable_address);
- scanf() is a predefined function in c used to take input data from the user.
- It is predefined in standard input output header file.
- scanf() function is case sensitive it means that if we write it in uppercase then we get an error at the time of compilation.