CSc 2310 Assignment #5 solution

$24.99

Original Work ?

Download Details:

  • Name: Homework-5-Array-List-jbfhsu.zip
  • Type: zip
  • Size: 15.44 KB

Category: You will Instantly receive a download link upon Payment||Click Original Work Button for Custom work

Description

5/5 - (4 votes)

Objectives:
1. To gain experience with using the Java programming language by being able to build classes.
Description of program:
You are to write a program name array_list.java that will do the following:
a. Prompt the user for a number that is greater than or equal to 50 (which serves as the minimum size of your ArrayList)
b. Generate this amount of random number one at a time and insert this number (one at a time) into an ArrayList. You must insert these numbers in order (i.e. in their correct location). For example if you already have 3 numbers in the list as in 3, 6, 8 and your next randomly generated number is 5, your new list must be 3, 5, 6, 8 before you even generate another random number, and so on and so on.
c. After you are finished, display the entire content of the ArrayList on the screen.
What to turn in:
Turn in:
A. A disk (flash drive) with the files array_list.javaandarray_list.classorarray_list.jar
B. A printout of the array_list.javafile.
C. Make sure your name is clearly written on both the disk and the print out.