This below
#include<iostream.h>
void product(); // prototype
int number1,number2,R;
void main()
{
cout<<"Please enter the numbers : ";
cin>>number1;
cout<<"Please enter the numbers : ";
cin>>number2;
product(); // calling the prototype
}
void product()
{
int R=0;
for(int i=1;i<=number2;i++)
{
R+= number1;
}
cout<<"The Result is : "<<number1<<"*"<<number2<<" = "<<R<<endl;
}
0 comments:
Posting Komentar