Question: Using JAVA: -use static variables and methods only if needed -encapsulation: make sure you protect your class variables and provide access to them though methods

Using JAVA:

-use static variables and methods only if needed

-encapsulation: make sure you protect your class variables and provide access to them though methods

Create 3 classes, app, football player and football team. The application (app) will use the two other classes (football player and football team).

The app will:

create 11 football players (you can place them in an array or ArrayList)

create a football team using the players above

use the football team instance (object) to display the information requested in the lab

a football player class has

at least 5 attributes from your choice

a method that returns the complete info about the player

a football team class has

a name and a mascot

11 football players

any other attributes (optional)

a method that:

displays all the information about a team including:

name

mascot, and

information on each player in the team

a method that:

display information about a specific player in the team using an input parameter such as the player position or player number for instance. For instance, from team A, displays information about the quarterback, or display information about player number 5.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!