Menu

[Solved]Write Member Function Date Class Named Void Validatedate Member Function Called Date Int M Q37271965

Write a member function for the Date class named voidvalidateDate()

This member function is called from the

     Date(int m, int d, int y)constructor

this member function will take the month, day, and year from theDate(int m, int d, int y) constructor and validate if theparameters input are valid

if the month and / or day are invalid, set the year to theconstant INT_MAX (in the limits.h llibrary)

use a switch statement – better than an if/else ladder

create a new class named D09Exception

this class can have one string data item

the getter and setter

use this string data item to pass information from the memberfunction vaidateDate() to the calling constructor

Expert Answer


Answer to Write a member function for the Date class named void validateDate() This member function is called from the Date(int m,… . . .

OR


Leave a Reply

Your email address will not be published. Required fields are marked *