C Program to accept User Input and Print

In this tutorial you will learn about the C Program to accept User Input and Print and its application with practical example.

C Program to accept User Input and Print

In this tutorial, we will learn to create a C program that will accept User Input and Print in C programming.

Prerequisites

Before starting with this tutorial we assume that you are best aware of the following C programming topics:

  • Operators in C Programming.
  • Basic Input and Output function in C Programming.
  • Basic C Programming.

What is an integer?

The integer is a positive or negative whole number including zero. These are the number real numbers.

Algorithm to print:-

Program to Print Integer 

As we all know the integer, character, float, or double value in c programming. In c programming, we can take the input from the user in character & number format. In this program, we will take input in integer format. The second will display the integer & character with the help of a small program. The integer & character are the most useful terminology in any programing language. For number/arithmetic manipulation in c programming, there are many predefined functions available.

With the help of this program, we can accept User Input and Print.

Program Code:

Output:-

In the above program, we have first initialized the required variable.

  • num = it will hold the input number value from the user.
  • ch = it will hold the character number value from the user.

Taking Input character from the user.

Taking the number value.

Printing the number value.

 

In this tutorial we have learn about the C Program to accept User Input and Print and its application with practical example. I hope you will like this tutorial.