Consider the following lines of Python code.
b = [23,44,87,100]
a = b[1:]
d = b[2:]
c = b
d[0] = 97
c[2] = 77
Which of the following holds at the end of this code?
a[1] == 77, b[2] == 77, c[2] == 77, d[0] == 97
a[1] == 87, b[2] == 87, c[2] == 77, d[0] == 97
a[1] == 87, b[2] == 77, c[2] == 77, d[0] == 97
a[1] == 97, b[2] == 77, c[2] == 77, d[0] == 97
a[1] == 87, b[2] == 77, c[2] == 77, d[0] == 97
Only this will hold.
Need a fast expert's response?
Submit order
and get a quick answer at the best price
for any assignment or question with DETAILED EXPLANATIONS!
Learn more about our help with Assignments:
Python