Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

Python Introducing Dictionaries Introducing Dictionaries Creating a Dictionary

Chai Chong Teh
Chai Chong Teh
25,709 Points

Can somebody tell me whether I misinterpret the challenge? I don't understand what went wrong here.

I am interpreting this as:

  1. create a variable "topic"
  2. assign the value of student's topic -> python to "topic"

Am I interpreting it wrongly?

creating_dictionaries.py
student = {'name':2, 'topic':'python'}
topic = student['topic']

I just had the same issue, it gets frustrating being new to coding and googling all types of information when you know the answer but the module is not accepting it!

1 Answer

Josh Keenan
Josh Keenan
19,526 Points

There is an issue with the challenge, the topic needs to be 'Python' with a capital P to pass in the second part of the challenge.

Chai Chong Teh
Chai Chong Teh
25,709 Points

Thank you, that was unexpected.

Josh Keenan
Josh Keenan
19,526 Points

Don't stress man, your code was perfect, believe in yourself cos you got this!