Question: 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

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!