Problem

Magic DatesThe date June 10, 1960, is special because when we write it in the following fo...

Magic Dates

The date June 10, 1960, is special because when we write it in the following format, the month times the day equals the year.

6/10/60

Design a class named MagicDate. The class constructor should accept, as integers, values for a month, a day, and a year. The class should also have a method named isMagic that returns true if the date passed to the constructor is magic, or false otherwise.

Write a program that asks the user to enter a month, a day, and a two-digit year as integers. The program should create an instance of the MagicDate class to determine whether the date entered by the user is a magic date. If it is, the program should display a message saying the date is magic. Otherwise it should display a message saying the date is not magic.

Step-by-Step Solution

Request Professional Solution

Request Solution!

We need at least 10 more requests to produce the solution.

0 / 10 have requested this problem solution

The more requests, the faster the answer.

Request! (Login Required)


All students who have requested the solution will be notified once they are available.
Add your Solution
Textbook Solutions and Answers Search
ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT