Create an object oriented java application

Assignment Help Basic Computer Science
Reference no: EM131381736

Task: Create an Object Oriented Java application to model a band competition.

Please make sure that your application meets all of the following requirements:

  • Your program should have an App class that contains you rmain() method, and a Band class as described below.
  • Create an array of 5 Band objects in your main() method.
  • For each Band, call it'scompete()method, which will assign a random score between 0 and 20 to to that band.
  • Calculate the top 3 finishers and write their information to a "winners.txt" file.
  • Create a UML Class Diagram for your Band class

Note:

  • Your Band class must be properly encapsulated
  • You must use a for loop somewhere in your project

For the sake of simplicity, you may assume that each band has:

  • A singer
  • A guitar player
  • A bassist
  • A drummer

In addition to the name of each player in the band, your Band class should store each band's:

  • Home town
  • Annual income from record sales
  • Genre of music (e.g. rock, punk, reggae, jazz)
  • Score in the competition (an integer between 0 and 20)

Your Band class must include the following methods:

  • constructor, which sets all of the values of each attribute.
  • A  compete() method, which creates a random value between 0 and 20 and assigns it to that band's score attribute.
  • getInfo() method, which returns all of the information about that band

Your App class must calculate the top 3 finishers (i.e. bands with the highest score attribute), and write all of their information to a file.

Note: You do not need to use the Scanner class to input information about the bands from the user.  You may hard code all of this information in your main() method, but you should not hard code any band information (names, etc.) in your Band class itself.

Reference no: EM131381736

Questions Cloud

Develop a very simple software : You have to develop a very simple software (i.e., program/product/component/system) in just 7 days. To develop a good-quality software, you would like to follow a particular software engineering process or more than one process. The goal is to rel..
What does your confidence interval suggest : The company must decide whether to now do a mass mailing. The mailing won't be cost-effective unless it produces at least a 5% return. What does your confidence interval suggest? Explain.
What should be the minimum age for transfer : Discuss whether or not juveniles should be transferred to adult court for certain crimes. Explain your reasoning. What crimes should be included? What should be the minimum age for transfer?
Explain the causes of crime using criminal justice thoeries : Select and discuss at least 2 specific crimes (homicide, rape, burglary, etc.) using criminal justice theories to discuss possible causes of these crimes, as well as the past and present police responses to these crimes. Have the courts and correc..
Create an object oriented java application : Your program should have an App class that contains you rmain() method, and a Band class as described below. Create an array of 5 Band objects in your main() method.
Mind requirements concerning security : When you design a network you keep in mind requirements concerning security, availability, recovery, and efficiency to name a few.
Check the conditions and find the p-value : The college president assured the trustees that this was just the kind of year-to-year fluctuation in fortunes that is to be expected and that, in fact, the school's success rate was consistent with the national average. Who is right?
Give a confidence interval for this prediction : If the market portfolio return for the current year is 10%, what is the stock's return predicted by the regression equation? Give a 95% confidence interval for this prediction.
Exploration of what is out there : Website benchmarking, to put it simply, is an exploration of what is out there, what is working well, and what is not. Begin by reading the article Understanding Website Benchmarking:

Reviews

Write a Review

Basic Computer Science Questions & Answers

  Use a count aggregate and a group by clause

Write a select statement that will display student id, student last name and the number of courses a student has been enrolled. You will need to join two tables, use a COUNT aggregate and a GROUP BY clause in your SELECT statement.

  Finding the largest element in an array

Prove that the classic recursive algorithm for the Tower of Hanoi puzzle (Section 2.4) makes the minimum number of disk moves needed to solve the problem.

  Write a program that prompts the user for a measurement

write a program that prompts the user for a measurement in meters and then converts it to miles, feet and inches.

  Draw an er diagram

a. Draw an ER diagram. Make sure each entity type has at least one key attribute. Document any assumptions you make. Avoid diagrams with a single entity. b. If you think the description is incomplete, list other data the database should store. c. Adj..

  Replacement part at much lower cost

You accidently broke your refrigerator door handle.The appliance company that made the refrigerator can express ship you a replacement handle, for which it has copyrighted the design. But instead of buying the copyrighted replacement part, you use..

  Variables does the data frame have

How many variables does the data frame have? How many rows does the data frame contain?

  Implement the fix num () function

It takes a number as a salary value and determines whether to multiply it by 1000 to put it on the proper scale. This is used to adjust salaries that are reported as, e.g., $100K.

  E-mail distribution group

An administrator needs to grant an e-mail distribution group of 100 members access to a database, how would the administrator proceed? The e-mail group is obsolete and can be dissolved.

  Develop a testing method for the hypothesis

Compare and contrast the modeling process with the scientific method: Make abservations; formulate a hypothesis; develop a testing method for the hypothesis; collect data for the test; using the data, test the hypothesis; accept or reject the hypo..

  Identify the greenest spot

The first step in this process is to send the video data to the patches so that you can interact with the color information directly. Then, you must identify the greenest spot.

  The woofwoof store specializes in food products

The WoofWoof Store specializes in food products for dogs and other household pets. In developing a new puppy food, company nutritionists have specified that the mixture must contain at least 16% protein, 13% fat, 12% vitamin, and no more than 15% fib..

  Develop a problem definition for angus

You have heard what Angus had to say about his customers. There are certainly more preferences that he can keep track of. Develop a problem definition for Angus, similar to the one developed for Catherine's Catering in this chapter.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd