Program to find the avg of two numbers

200 views

Published on

This is for the students of computer science for their projects

Published in: Education
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
200
On SlideShare
0
From Embeds
0
Number of Embeds
2
Actions
Shares
0
Downloads
3
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Program to find the avg of two numbers

  1. 1. // Program to find the avg of two numbers #include <iostream.h> #include <conio.h> void main() { clrscr(); int n1,n2; float avg; cout<<"n Enter the number 1"; cin>>n1; cout<<"n Enter the number 2"; cin>>n2; avg=(n1+n2)/2; cout<<"nThe Average is: "<<avg; getch(); }

×