user defined functions in c++ part 2
#include <iostream>
using namespace std;
int sum(int x,int y)
{
int c=x+y;
return c*2;
}
int main()
{
int a,b;
cin>>a>>b;
cout<<sum(a,b)<<endl;
}
#include <iostream>
using namespace std;
int sum(int x,int y)
{
int c=x+y;
return c*2;
}
int main()
{
int a,b;
cin>>a>>b;
cout<<sum(a,b)<<endl;
}