#include<stdio.h>
int main() {
int a, b, sum;
printf("
Enter two no: ");
scanf("%d %d", &a, &b);
sum = a + b;
printf("Sum : %d", sum);
return(0);
Enter two integers: 12
11
12 + 11 = 23
#include <stdio.h>
int addNumbers(int a, int b)
{
int sum = a + b;
return sum;
}
int main(void)
{
int a = 4;
int b = 7;
printf(addNumbers(a,b));
return 0;
}
#include <stdio.h>int main(){ int a, b, sum;printf("Enter two integers");scanf("%d %d", &a, &b);sum = a + b; printf("%d + %d = %d", a, b, sum);return 0;}
#include <stdio.h>
#include <stdlib.h>
int main()
{
int num1,num2,i; //Variable declaration
printf("Enter the first number: ");
scanf("%d",&num1);
printf("Enter the second number: ");
scanf("%d",&num2);
for(i=0; i<num2; i++){
num1++;
}
printf("Sum of two numbers : %d ",num1);
return 0;
}