Write a CH program to read from an input filc, games, surnames, and university registration dates for the students. In y
Posted: Fri May 20, 2022 12:18 pm
Output all the correct or corrected inputs to another file named as one txt) as shown below: Output Kobe Bryant 7 July 199? Sue Bird 10 January 1999 Lebron James 15 October 2000 Tina Thompson 19 Junc 2010 In your program, se gomposition to create two classes Date and Swaewr Date class has the following data members and functions: , hay titan gel month integer) year integer) A constructor function should make assignments using member initialization Student class as the following data members and functions: firstName(string) ►lastName (string) Dute registrationday a registrationday is an object with data type Dule class) A constructor to initialize the name and also send the day, mouth, and year to the constructor of the registrationday object. ► Set Month function that gets a string parameter Day() function that returns the day of the registrationdale Yen) function to retium the year of the registrationdale prin info) function, has to print the first me, last name, registrationdate day, month, and year of the student 2/3
In You should input cach line from the input file (input.txt) and using exception handling check the day, month and year. If exceptions are thrown, in your first catch output an error message if the day or car is incomst. In your second catch, try to correct the month according to the first 3 characters. If you can correct the meth, cutput the corrected information onto the output file. You have to ensure the simple run of catch as follows: Incorrectly inputted month: Janeary is corrected to January Incorrectly inputted month:Octobr is corrected to October Incorrectly input for day/year: 4024 Incorrectly inputted month: Jene Incorrectly input for day/year:43