Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

IN JAVA: Create a LinkedNode data type that includes the following data along with the appropriate getters/setters/constructors/toString: -name (String) -age (int) -favColor (String) -next (LinkedNode)

IN JAVA:

Create a LinkedNode data type that includes the following data along with the appropriate getters/setters/constructors/toString:

-name (String)

-age (int)

-favColor (String)

-next (LinkedNode)

Create a testing program that uses only the methods you coded in LinkedNode and does the following (in this specific order):

1.create a reference variable to indicate the beginning of your list

2.create and link 4 new nodes so that you basically have a singly linked list

3.display the list (create a method that uses a loop to do this)

4.add 1 more node

5.display the list

6.delete node 3

7.display the list

8.delete the last node

9.display the list

-Draw your final list on paper

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

Database Systems An Application Oriented Approach Complete Version

Authors: Michael Kifer, Arthur Bernstein, Richard Lewis

2nd Edition

0321268458, 978-0321268457

More Books

Students also viewed these Databases questions