In this programm we will start with “Sum and Average of Two Numbers “. Write a program to sum and average of two number program in C after that execute the program and program will print output.
#include<stdio.h> #include<conio.h> void main() { int num1,num2,sum,ave; clrscr(); printf("\n Enter First No:"); scanf("%d",&num1); printf("\n Enter Second No:"); scanf("%d",&num2); sum=num1+num2; printf("\n The Sum of Two No=%d",sum); ave=sum/2; printf("\n The Ave=%d",ave); getch(); }