C Program to Add two Integers
Given two numbers A and B. The task is to write a program to find the addition of these two numbers.
Input: A = 2, B = 3 Output: 5 Input: A = 3, B = 6 Output: 9
In the below program to add two numbers, the user is first asked to enter two numbers and the input is scanned using the scanf() function and stored in the variables and . Then, the variables and are added using the arithmetic operator and the result is stored in the variable sum.
Below is the C program to add two numbers:
Enter two numbers A and B : 2 3 Sum of A and B is: 5