Suppose that you have defined in your program three function with the following
ID: 3531551 • Letter: S
Question
Suppose that you have defined in your program three function with the following function declarations:
double myfunction(double num1, double num2);
double myfunction(double num1, int num2);
double myfunction(double num);
Which function definition would be used in the following function call and why?
double x=1.0, y=2.3;
y = myfunction(x, 5.0);
Which function definition would be used in the following function call and why?
double x=1.0;
y = myfunction(2, 3.0);
Which function definition would be used in the following function call and why?
double x=1.0;
x = myfunction(2, 3);
Which function definition would be used in the following function call and why?
double x=1.0;
x = myfunction(2);
Thanks for all your help!!!
Explanation / Answer
1double myfunction(double num1, double num2); will be used
2double myfunction(double num1,double num2);
3double myfunction(double num1, int num2);
4double myfunction(double num);
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.