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 Python Basics (2015) Python for Beginners Correct errors

could someone help me with this quiz, finding it very hard.

h

errors.py
print("Hello")
print(caio)

print("Let's_do_some_math!")
print(5 + "5")

print("Thanks for playing along!")

1 Answer

jonlunsford
jonlunsford
15,480 Points

You are looking for the errors...

print(caio)

the term 'caio' is a variable, but it has not been defined such as caio = "hello", or caio = 5. You must assign something to a variable before you use it. In this case, there has been no assignment.

print(5 + "5")

In this statement, you can't add a string to an integer. In this case 5 is an integer, and "5" is a string. You could print(5+5) or print("5" + "5").