Why appending in the list gives this output?

l5=[1,2]
l5.append(3)
l5.append(l5)
print(l5)

output:
[1, 2, 3, […]]

Hey @ARYAN27, I have solved this query a few days back in a lot of detail. Please click on this Python list append doubt

Hope this clears your doubt.
Happy Learning :slight_smile:

1 Like