Write a program that asks the user to enter two integer numbers. the main function then passes these numbers to a function named exp that calculates the multiplication of these numbers and print the exponential value of the result of multiplication
Answer:
I have written the below program based on your requirements.
The below code has no-error and it is working perfectly.
I have also attached the Output Screenshot that I got by running the below program.
Output:
*******************************************************************************************************************************
Code:
#include<bits/stdc++.h>
using namespace std;
void exp(int a, int b)
{
int c= a * b;
double e=exp(c);
cout<<"\nExponent ("<<c<<") is
"<<e;
}
int main()
{
int a,b;
cout<<"\nEnter two integer numbers : ";
cin>>a>>b;
exp(a,b);
}
Get Answers For Free
Most questions answered within 1 hours.