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
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started