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 trialTsung Wei Tsai
583 PointsI got different result using same code in the video
my_list
['a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 9, 'j']
my_list[8] = ['i']
my_list
['a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', ['i'], 'j']
it shows ['i'] instead of 'i'. I follow the tutor but python gave different result. Do anyone know where did I make mistake? Thank you
1 Answer
Ezekiel dela Peña
6,231 PointsI think you should do it like this:
my_list[8] = 'i'
because if you're going to put ['i']. The python will read it as a (['i'] string) not as (i char).