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 trialName:GoogleSearch orJonathan Sum
5,039 PointsLet's practice with indexes! Make a new variable named var1 that is either a list or a string. Make sure that var1[5],
Make a new variable named var1 that is either a list or a string. Make sure that var1[5], My code is: varl='invent' varl[5] the code above works in my python shell. i don't know why it doesn't work in treehouse. It said 'varl' is not defined.
varl='invent'
varl[5]
2 Answers
Steven Parker
231,248 PointsThe challenge asks you to make a variable named "var1" (v-a-r-one).
It looks like you created a variable named "varl" (v-a-r-lowercase "L")
Quinn Thompson
1,227 Pointslol.. perhaps the name of this variable needs changing because I made this exact mistake too >.>