Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialChandler Pettibone
2,191 PointsAttributeError: 'list' object attribute 'extend' is read-only
So I am super confused why I am getting the Attribute Error that extend is read only. In the video before the challenge we added James and Guil to the attendees using attendees.extend. However, when I did beatles.extend = others and listing the others out, the computer wasn't happy.
Thanks for the help!
beatles = ["John"]
others = ["George", "Ringo"]
# Your code here
beatles.append("Paul")
beatles.extend = others
1 Answer
Eric M
11,546 PointsHi Chandler,
You're pretty close!
.extend takes an argument the same way as .append, it doesn't take its argument via the assignment operator (equals sign, =)
That should be all you need