The first three assignment statements in the insert method create a new node and adjust links to hook it into the positional list’s linked structure. Assume that a list contains the elements A and B and that the programmer has run a single next to advance the cursor. Draw box and pointer diagrams to show the states of the list before insert(C) is run and after each of the three statements.
Already registered? Login
Not Account? Sign up
Enter your email address to reset your password
Back to Login? Click here