Question: In C# In C# 2- Create a Date class with integer data members for year, month, and day. Also include a string data member for
2- Create a Date class with integer data members for year, month, and day. Also include a string data member for the name of the month. Include a method that returns the month name (as a string) as part of the date. Separate the day from the year with a comma in the method. Include appropriate constructors, properties, and methods. Override the ToString() method to display the date formatted with slashes (/) separating the month, day, and year. Create a second class that instantiates test the Date class. Output Enter a number representing the Month: 10 Enter a number representing the Day: 19 Enter a number representing the Year: 2018 First Test 10/19/2018 Second Test: 3/20/2010 Third Test Date: 2/2/2016 Last Test October 3, 2017
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
