Question: Finally design a java class Client with the main ( ) method that does the following: Create an Object of Type Scores using the overloaded
Finally design a java class Client with the main method that does the following:
Create an Object of Type Scores using the overloaded constructor and pass the value
Use a for loop to populate the list in Scores object with random numbers between
and inclusive. Use the Random class from java.util package to generate pseudorandom numbers
Call toString to print the contents of the Scores object.
Call the add method to add the number to Scores object.
Print the current size of the list in the Scores object.
Call the remove method to randomly remove a number from Scores class
Get the number at the th index position
Print the frequency of the number returned by the previous step occurs in Scores class
Call the appropriate overloaded remove method to remove the first occurrence of number at the th index position from Scores class
Print the frequency that this number now occurs in Scores class
Check whether the array in Scores object contains the number
Use JavaDoc commenting styles in the Scores class and the Client Review Section in the textbook Make sure to provide a block comment at the top that provides description of each class and a JavaDoc comment for each method.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
