White RoomNEW White Room DSA

New Object Or Same Object

Starting fresh each time from a = [1, 2, 3], which of these leave b referring to a genuinely new list object rather than an alias of a? Select all that apply.

  • b = a
  • b = list(a)
  • b = a[:]
  • b = a, then b += []