Question
Create a program that allows you to create a fantasy football roster based on the existing list of available players. Your team can only have
Create a program that allows you to create a fantasy football roster based on the existing list of available players.
Your team can only have 5 players, so create an array that can store 5 possible players.
Prompt the user to pick 5 players to add to their team. If the player is available in the list of availablePlayers, then add that player to the users array, and remove that player from the availablePlayers list. Then prompt the user to pick another player. Once all five players have been added, then print the list in the console.
Create a search method to find the index at which the player is located in the availablePlayers list so you can remove the player, and make sure that they are an eligible pick.
Here is a sample run of the program:
import java.util.ArrayList; import java.util.Scanner;
public class FantasyFootball { public static void main(String[] args) { ArrayList
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started