Question
d_date.h ^ date_except.h ^ driver.cpp ^ a) Overload the relational operators (==, !=, ) to compare dates. Two dates are to be compared by chronology
d_date.h ^
date_except.h ^
driver.cpp ^
a) Overload the relational operators (==, !=, ) to compare dates. Two dates are to be compared by chronology of the year. For example: date(3,5,1999) != date(3,7,1999) (implement as external free function) date(3,5,1999) == date(3,5,1999) (implement as external free function) date(5,5,1977) > date(10,24,1973) (implement as member function) date(12,25,1944)
b) Write member function operator++ that can increment the date by one day.
c) Overload the input and output stream operators so that the date can be read/written as follows: date date1; cin >> date1 >> // read in as 12/25/1944 cout
Use the driver.cpp file which can be found on BlackBoard. You will also find an input file at this location to run with the driver.cpp file.
* : 1.2. wulan slir 15 1 .. .1.4 las Iru rer: pualle a Xerr a rrt us. Irt I. r: Klan": E N Irarr; werk. EX T V **: LAS IR... KLASI Elsas CEO : .. turet exstler Euter ricret at-iri 1-25, Irt: ret at-irani ENT; E 13 it ca la seb i -verir; wertli Ele Tur k ana wetian : rapor EVE T E and optimi Me t e te veroorker Alperesstre . // File: Driver.cpp // Note: Used to test our date class with overloaded functions #include
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started