It copies a list right? but in the code I’m looking at its x = x[:] which I don’t understand. How can both copies be called the same thing?
It copies a list right? but in the code I’m looking at its x
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
The right is evaluated first, placed into a temporary variable, and x is re-assigned to the temp variable. You never see it, of course.