View the step-by-step solution to:

PLEASE HELP! ASSISTANCE IS GREATLY NEEDED AND WILL BE APPRECIATED! *NOTE: THE CODE FOR ID, NAME, AND COURSE MUST BE HARDCODED, NOT ASKED BY THE USER...

PLEASE HELP!!!!!!! ASSISTANCE IS GREATLY NEEDED AND WILL BE APPRECIATED!!!!!

*NOTE: THE CODE FOR ID, NAME, AND COURSE MUST BE HARDCODED, NOT ASKED BY THE USER TO INPUT. PLEASE AND THANK YOU IN ADVANCED!!


Part 2: Students and Courses

Java review


You may use an IDE or a text editor, but I will test this by compiling and running from the command line so be sure to test it that way. (No packages allowed) The program will not compile and run at the command line if you include any package statements.


Here are the steps.

(1) Create: A Student class containing an ID, a last name, and a list of course names such as "COP2210" or "COP2250". The ID should be an integer which is printed with leading zeros.

(2) Create: A class named StudentTest that contains a List of students. This should not be a string of multiple courses. Do not use the list provided here. In the class constructor, create 15 students and add them to the list. Each student's ID must be different. Each student you add to the list must contain at least 3 different course names. At least one should have two course names and at least one should have four course names. Make sure the students do not all have the same courses, although there should be some overlap (see the sample below). The student names must be inserted into the list in random order (not sorted).

(3) Sort the list in ascending order by student last name and display the list. For each student, display the ID with leading zeros, last name, and list of courses on a single line. Here is sample output. Note how the tab character is inserted after the name to line up the next column containing courses. Be sure there is no trailing comma at the end of the list of courses.



Criteria:


Students and Courses Part 1: Student Class

The Student class should have an ID, a Lastname, and a list of course names. The ID is an integer, the Lastname is a string, the list of courses is an ArrayList.


Students and Courses Part 1: StudentTest

The StudentTest class should create an ArrayList with at least 15 different students, each with from 2 - 4 course names. At least one student should have 2 courses and at least one student should have 4 courses. The List should not be created in sorted order.


Students and Courses Part 1: OutputOutput should look like the sample with at least 15 students with the last names in alphabetical order. At least one student has only two courses and at least one has four courses. The ID should have leading zeros.


Thank you very much again!

Recently Asked Questions

Why Join Course Hero?

Course Hero has all the homework and study help you need to succeed! We’ve got course-specific notes, study guides, and practice tests along with expert tutors.

-

Educational Resources
  • -

    Study Documents

    Find the best study resources around, tagged to your specific courses. Share your own to gain free Course Hero access.

    Browse Documents
  • -

    Question & Answers

    Get one-on-one homework help from our expert tutors—available online 24/7. Ask your own questions or browse existing Q&A threads. Satisfaction guaranteed!

    Ask a Question