Question: clone ( ) : try Create the clone by calling super.clone. Make the clone's head point to a new dummy head node. Make the next

clone(): try
Create the clone by calling super.clone.
Make the clone's head point to a new dummy head node.
Make the next and previous in the clone's dummy head node point
back to the clone's dummy head node.
Initially set size of the clone to 0.
Iterate through this linked list, adding each element to the
clone by calling the clone's add method.
Return the clone.
catch CloneNotSupportedException
If you've done things correctly, this catch block should
never execute. But for good style throw some sort of
RuntimeException.

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!