Chapter 3: Problem 15
Create a class called Date that includes three pieces of information as instance variables- \(a\) month (type int), a day (type int) and a year (type int). Your class should have a constructor that initializes the three instance variables and assumes that the values provided are correct. Provide a set and a get method for each instance variable. Provide a method displayDate that displays the month, day and year separated by forward slashes ( \(/\) ). Write a test application named DateTest that demonstrates class Date's capabilities.
Short Answer
Step by step solution
Key Concepts
These are the key concepts you need to understand to accurately answer the question.