Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Total: 40 points Extra Credit: 10 points Name of Project: YourUsername_P1. My project name would be mutsuday_P1. Please use this format as it helps during

image text in transcribed
image text in transcribed
Total: 40 points Extra Credit: 10 points Name of Project: YourUsername_P1. My project name would be "mutsuday_P1". Please use this format as it helps during grading. Place all.java files in the same project. The goals of this project are to learn to write programs using methods, Arrays and ArrayLists. 1. (20 points) Create a Java Main Class file titled "TeamScore.java" (5 points) Write a public method (static method) winnerfint points 1, int points2) that takes two scores and returns a boolean. If points1 is greater than points2 the method returns true and if points1 is less than points, the method returns false. Points should not be tied but return false if that ever happens. The method returns false if none of the conditions are true. (15 points) In your main method, declare two arrays - the first array is team 1's points and the second array is opponents' points in corresponding games, i.e., the first items in the arrays are the scores for each team in the first game and so on. The arrays are the same length. Hard code the values of the arrays, that is, declare the arrays with known values. User input via keyboard or random number generation is not needed. Do NOT use ArrayLists. Using the method winner from above, calculate and print the win/loss record of teami. If all games were won, print out a message saying that team has a perfect record. Here are some examples: 1. (20 points) Create a Java Main Class file titled "TeamScore.java" (5 points) Write a public method (static method) winner(int points 1, int points2) that takes two scores and returns a boolean. If points 1 is greater than points2 the method returns true and if points1 is less than points, the method returns false. Points should not be tied but return false if that ever happens. The method returns false if none of the conditions are true

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Murach's SQL Server 2012 For Developers

Authors: Bryan Syverson, Joel Murach, Mike Murach

1st Edition

1890774693, 9781890774691

More Books

Students also viewed these Databases questions

Question

Let W1 Answered: 1 week ago

Answered: 1 week ago

Question

How should Grandview go about implementing a global PM system?

Answered: 1 week ago

Question

Define marketing concepts.

Answered: 1 week ago

Question

1 what does yellow colour on the map represent?

Answered: 1 week ago