Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Please and thank you! Write a C++ program that uses a class (Date) and a driver (DateDriver) to display a date to the screen. You

Please and thank you!

Write a C++ program that uses a class (Date) and a driver (DateDriver) to display a date to the screen. You must write a driver and a class using separate files for full credit.

Requirements for the Date Class Data Members 1. integer to store the month 2. integer to store the day 3. integer to store the year Be sure to use the appropriate access modifier for these. Member Functions 1. One 3-argument constructor The constructor has three integer arguments representing the month, day, and year values. Use member initializers. 2. Getters and setters for each of the above integers Each data member needs its own setter and its own getter function, for a total of six functions. Be sure to use the const keyword where appropriate. 3. displayDate function This function uses the integer data members and displays the date to the screen using the format mm/dd/yyyy. Requirements for the DateDriver Program

Data members none Functions 1. main Instantiate an object of type Date, passing any three integers to the constructor. Use integers that form a valid date. You can hard code values here. Call the displayDate function of the Date object to display this date to the screen. Prompt the user for three new integer values. Be sure to use prompts that explain what the user needs to do. Call the appropriate setter functions of the Date object, using the three values input by the user. Call the displayDate function of the Date object to display the new date to the screen. General Requirements For complete credit, you must:

1. MEET ALL REQUIREMENTS ACCORDING TO THE INSTRUCTIONS Follow the instructions as written for completing this project, even if you [think you] know a better way to do something. 2. INCLUDE COMMENTS Include comments in your code. There must be a comment at the top of each source code or header file that includes your name, the assignment number, and a description of the code in that file. There must be comments at each important step in your algorithm that describes that step. 3. FOLLOW BEST PRACTICES Follow best practices in C++ programming, including, but not limited to, appropriate use of private/public, appropriate use of classes and/or header files, sets & gets, white space, alignment, meaningful variable names, naming conventions, using statements, etc. Points will be deducted for sloppy code that is hard to read, even if it works, so pay attention to these details. 4. SUBMIT ALL FILES BEFORE THE DUE DATE Submit a .zip of ONLY source code files to the dropbox for this assignment on Canvas before the due date. Do not submit anything except .cpp and/or .h, within a zip. Do not submit .exe files. Do not submit a folder structure. Do not submit project files from an IDE

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Machine Learning And Knowledge Discovery In Databases European Conference Ecml Pkdd 2022 Grenoble France September 19 23 2022 Proceedings Part 4 Lnai 13716

Authors: Massih-Reza Amini ,Stephane Canu ,Asja Fischer ,Tias Guns ,Petra Kralj Novak ,Grigorios Tsoumakas

1st Edition

3031264118, 978-3031264115

More Books

Students also viewed these Databases questions

Question

1. Identify three approaches to culture.

Answered: 1 week ago

Question

3. Identify and describe nine cultural value orientations.

Answered: 1 week ago

Question

4. Describe how cultural values influence communication.

Answered: 1 week ago