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 trial

Python Introducing Lists Meet Lists Deletion

craigs_lunch

I'm getting the following when I try to run an example in the training through the console. Is there a reason why I cannot get the emoji taco to show up like on the video?

treehouse:~/workspace$ python -i wishlist.py
Suggested gift: Learning Python: Powerful Object-Oriented Programming - Mark Lutz

craigs_lunch = "\N(TACO)"
File "<stdin>", line 1
SyntaxError: (unicode error) 'unicodeescape' codec can't decode bytes in position 0-1: malformed \N character escape

Angela Anders Hi :], i asked the same question and it appears that your computer does not support this. see this discussion; https://teamtreehouse.com/community/just-wanted-to-ask-why-i-dont-get-the-taco-emoji

Steven Parker
Steven Parker
231,271 Points

Your issue was different, the decoding was working but it did not display.

3 Answers

Steven Parker
Steven Parker
231,271 Points

Named escapes should have the name enclosed in braces instead of parentheses.

So instead of "\N(TACO)", try: "\N{TACO}".

Okie dokie. Makes sense. Thanks

does this example only work with TACO? I tried mikes_lunch = "\N{PIZZA}"but it tells me that its a unicode error. wanted to test the potential of this.

Steven Parker
Steven Parker
231,271 Points

Perhaps just the name is the issue, try the unicode: mikes_lunch = "\U0001f355"
As a last resort you could also cut and paste the actual character :point_right: 🍕