Dark mode logo
Last Updated:
Find the sum of two numbers in c

C Program to find sum of 2 numbers


Input: Input two numbers
output: Sum of the numbers input

  1. Start
  2. Input two numbers
  3. Sum = a+b
  4. Print Sum
  5. Stop

C Program


#include <stdio.h>
int main( )
int a, b, sum;
printf("Enter first number: ");
scanf("%d", &a);
printf("Enter second number: ");
scanf("%d", &b);
sum = a + b;
printf("The sum of %d and %d is %d", a, b, sum);
return 0;
Note: This Program was created using visual studio code. The Program file can be downloaded by clicking here