Showing posts with label Addition of Two Numbers. Show all posts
Showing posts with label Addition of Two Numbers. Show all posts

Saturday, 14 January 2012

Program To Find Sum of Numbers Using Function In C++

#include<iostream.h>
#include<conio.h>
#include<math.h>
main()
{
clrscr();
int a,b,c;
cout<<"Enter numbers=";
cin>>a>>b;
sum(a,b);
getch();
}
 void sum(int x,int y)
 {
 int z;
 z=x+y;
 cout<<z;
 }