Member-only story

Input Output Functions in C Language with Examples -

Bipsmedium
2 min readJun 19, 2022

--

Hi friends, in this tutorial, you will know the input output functions in C language. Basically, there are two functions mainly to read input from input devices and display the output to the output devices. Let’s discuss them one by one.

Also read, Constant in C with Example

Below are the two input output functions in C language

scanf function in C

scanf() function is used to read or input the values of the variables from the standard input device such as keyboard etc.

Syntax:-

scanf("format string", &V1, &V2..........&Vn);
where v1, v2...Vn is the variable whose values are to be read from the keyboard.
"format string" is the control string that represents the data type such as integer, float, character and double, etc.

Below is the table of format strings for various data types

int

Represents a decimal integer value
Represents an unsigned integer value
Represents an unsigned octal value
Represents an unsigned hexadecimal value

float / double

Represents a floating-point value
Represents a floating-point value in decimal or exponential form

--

--

Bipsmedium
Bipsmedium

Written by Bipsmedium

Hi, This is Biplab and I am a PHP laravel developer and other open source technologies. I am here to share my experience with the community.

No responses yet