Fill in the blanks (...)C++ homework
#include using namespace std;class Date {public:…..void setDate(int date_day, int date_month, int date_year){ //put the date……………….}void getDate(){//show the date………}}; // end class //...int main(){int day,month,year;cout<"please enter="" the="" currents="" day,="" month="" and="">"please><>cout <"enter day:="">"enter>cin >> day;cout <"enter month:="">"enter>cin >> month;cout <"enter year:="">"enter>cin >> year;Date today;today.setDate(day,month,year);today.getDate();Date yesterday;yesterday.setDate(day-1,month,year);cout<"yesterday>"yesterday>yesterday.getDate();return 0;}
void setDate(int date_day, int date_month, int date_year){ //put the date……………….}
void getDate(){//show the date………}}; // end class //...
int main(){int day,month,year;
cout<"please enter="" the="" currents="" day,="" month="" and="">"please><>cout <"enter day:="">"enter>cin >> day;cout <"enter month:="">"enter>cin >> month;cout <"enter year:="">"enter>cin >> year;
Date today;
today.setDate(day,month,year);today.getDate();
Date yesterday;yesterday.setDate(day-1,month,year);cout<"yesterday>"yesterday>yesterday.getDate();
return 0;}
Already registered? Login
Not Account? Sign up
Enter your email address to reset your password
Back to Login? Click here