Skip to main content

2. Addition of two numbers with three Integers

 Hey Folks,

  Today, I'm going to share an addition of two number with three integers, we have two integer addition and three integer addition. Today we are going to know the program of three integer addition in different methods.

Method I: 

#include<stdio.h>
#include<conio.h>
main()
{
int a,b,c;
printf("Enter First Number:");
scanf("%d",&a);
printf("Enter Second Number:");
scanf("%d",&b);
c=a + b;
printf("Addition of two numbers: %d",c);
getch();
}


Method II:

#include<stdio.h>
#include<conio.h>
main()
{
int a,b,c;
printf("Enter Numbers to add: ");
scanf("%d%d",&a,&b);
c = a+b;
printf("Addition of two number is: %d",c);


Thank you.

Comments