Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Visual studio: c++ Design a program that uses a class called Date. The Date class should store a date in three integers: month, day, and

Visual studio: c++

Design a program that uses a class called Date. The Date class should store a date in three integers: month, day, and year. There should be member functions to print the date in the following forms:

1/15/13

January 15, 2013

15 January 2013

The class: variables: month, year, day

string array to store the months names

constructors: default and Date(int, int, int)

functions:

setNames (to initialize the string array to the months names),

modifier functions for month, day, year

accessor functions for month, day, year

displayDate1, displayDate2, displayDate3

Input Validation: Do not accept values for the day greater than 31 or less than 1 (dont worry about different months here). Do not accept values for the month greater than 12 or less than 1.

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

Step: 3

blur-text-image

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

Database And Expert Systems Applications 24th International Conference Dexa 2013 Prague Czech Republic August 2013 Proceedings Part 1 Lncs 8055

Authors: Hendrik Decker ,Lenka Lhotska ,Sebastian Link ,Josef Basl ,A Min Tjoa

2013 Edition

3642402844, 978-3642402845

More Books

Students also viewed these Databases questions

Question

=+derived from the assignment will balance the costs?

Answered: 1 week ago