Given the following class, what is syntactically wrong with the implementation of the display function?
class Rational
{
public:
Rational();
Rational(int numer, int denom);
Rational(int whole);
int getNumerator();
int getDenominator();
friend void display(ostream& out, const Rational& value);
private:
int numerator;
int denominator;
};
void display(ostream& out, const Rational& value)
{
out << value.getNumerator() << '/"<
a. nothing
b. value must be not be pass by reference
c. The get functions are not const functions
d. out should be pass by value
c. The get functions are not const functions
You might also like to view...
The final result of a ________ is the adjustment of two bank accounts electronically
Fill in the blank(s) with correct word
Which of the following is a tunneling protocol used to make VPN connections?
A. PPP B. SLIP C. PPTP D. STP