Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Student Learning Outcomes. After completion of this lab, students will be able to write a Java program that Creates ArrayList Uses ArrayList methods Activity -

Student Learning Outcomes. After completion of this lab, students will be able to write a Java program that

Creates ArrayList

Uses ArrayList methods

Activity - Implement a program that implements a contact list using an ArrayList.

The program will contain two classes, ContactListEntry, and ContactList.

ContactListEntry

Instance variables: name, phone number and email address.

Default and parameterized constructors

Accessor and mutator methods.

ContactList

Create an ArrayList of ContactListEntry objects

Create at least 5 ContactListEntry object and add them to the ArrayList. No user input just hard code the entries.

Perform the following:

Use a for loop to display the ArrayList entries in a nicely format display.

Remove an entry from the list.

Use an enhanced for loop to display the ArrayList entries in a nicely format display.

Insert a new contact between the 2nd and 3rd entries in the list.

Display the list using either type loop.

Overwrite the last entry with a new contact. (Code should work for any size list)

Display the list using either type loop

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

Professional IPhone And IPad Database Application Programming

Authors: Patrick Alessi

1st Edition

0470636173, 978-0470636176

More Books

Students also viewed these Databases questions

Question

Distinguish between poor and good positive and neutral messages.

Answered: 1 week ago

Question

Describe the four specific guidelines for using the direct plan.

Answered: 1 week ago