project:_2
#include<stdio.h>
int main()
{
int a;
int b;
printf("enter the first number a\n");
scanf("%d", &a);
printf("enter the second number b\n");
scanf("%d", &b);
printf("the sun is %d\n", a+b);
return 0;
}
// project:_2 (addition of numbers)
#include <stdio.h>
int main()
{
int a,b;
printf ("enter the first number: ");
scanf ("%d", &a);
//data type symbol jab bhi use kiya jata he vo kisi variable ke respect me
use kiya jata,
//he jise "," ke bad mention kiya jata he.
//like here %d variable a ke liye ko print karega
printf ("enter the second number: ");
scanf ("%d", &b);
//data type symbol jab bhi use kiya jata he vo kisi variable ke respect
me use kiya jata,
//he jise "," ke bad mention kiya jata he.
//like here %d variable b ke liye ko print karega
printf ("the sum is: %d",a+b);
//data type symbol jab bhi use kiya jata he vo kisi variable ke respect me
use kiya jata,
//he jise "," ke bad mention kiya jata he.
//like here %d variable b ke liye ko print karega
return 0;
}
output:_
enter the first number: 6
enter the second number: 8
the sum is: 14
No comments:
Post a Comment
here we are to help you.you can watch videos and get information about :- (1) scientific facts (2) education (3) gaming (4) music (5) lyrics (6) cartoons and many more.So keep watching keep learning, thank you.