Solved

insert(1, ...) — "position 1" is second?

OliviaPyOP

The task says the backup takes position 1. Is that the second place?

4

Comments 4

Join the discussion

Already have an account? Log in

  1. EmmaCodes Solutionreplies: 2

    Yes, indexes start at 0, so index 1 is the second item. insert(1, x) puts x there and shifts everyone after it right.

    4
    1. FreyaL

      remove() deletes the first matching value, pop() removes by index and returns it. Stage 2 uses pop for that reason.

      1