Computer Science, asked by geek66, 1 year ago

Write a C program to calculate sum of two numbers?

Answers

Answered by uddeshpawar
12
This is a simplest program for calculate the sum of two numbers.

#include<stdio.h>

int main()

{

int a, b, sum;

printf("\nEnter two no: ");

scanf("%d %d", &a, &b);

sum = a + b;

printf("Sum : %d", sum);

return(0);

}

Hope it helps you.

Answered by hornyboy69
15
\* C Program to Add two numbers *\

# include < stdio.h >
int main( )
{

int a, b, sum;
printf(" Enter the First Number : ");
scanf("%d",& a);
printf("\n Enter the Second Number : ");
scanf("%d",& b);
sum = a + b;
printf("\n Sum of two Number : %d",sum);
return ( 0 );

}

thanks

PrettyDoll1: sorry but u r username is not good so u may unfollow me
PrettyDoll1: I am not able to follow u back so
hornyboy69: whyyy
PrettyDoll1: i dont like it
hornyboy69: so you dont have to like it just follow n..
Similar questions