How to add to integers in C programming
#include<stdio.h>
int main(int argc, char *argv[])
{
int a, b;
printf("Enter number a\n");
scanf("%d", &a);
printf("Enter number b\n");
scanf("%d", &b);
printf("The sum is %d\n", a+b);
return 0;
}
Now give two integers as user input and press "Enter" and check the results.
If you have any doubt comment down below.
Thankyou.
ReplyDelete