Solved

Given the Following Class, What Would Be the Best Declaration

Question 14

Multiple Choice

Given the following class, what would be the best declaration for a constructor that would allow the user to initialize the object with an initial age and cost?
Class Wine
{
Public:
Wine) ;
Int getAge) ;
Float getCost) ;
Private:
Int age;
Float cost;
}


A) int getAgeint newAge) ;
B) Wine) ;
C) Wineint age) ;
D) Wineint newAge, float newCost) ;

Correct Answer:

verifed

Verified

Unlock this answer now
Get Access to more Verified Answers free of charge

Related Questions