You created a class named Game that included two Team objects that held data about teams participating

Question:

You created a class named Game that included two Team objects that held data about teams participating in a game. Modify the Game class to set the game time to the message Game cancelled! if the two teams in a game do not have the same value for the sport. (In other words, a girls’ basketball team should not have a game  cheduled with a boys’ tennis team.) Save the revised class as Game.java. Write a program to demonstrate a valid and an invalid game.

Fantastic news! We've Found the answer you've been seeking!

Step by Step Answer:

Related Book For  answer-question

Java Programming

ISBN: 978-1337397070

9th edition

Authors: Joyce Farrell

Question Posted: