Python String Fundamentals
Learn the basics of Python strings: text values, quotes, variables, empty strings, and why "25" is not the same as 25.
Sounds useful?
Jump into the interactive version.
No setup. No account. Just Python.
Python String Fundamentals
Learn the basics of Python strings: text values, quotes, variables, empty strings, and why "25" is not the same as 25.
Jump into the interactive version.
No setup. No account. Just Python.
Text is everywhere in code: names, messages, labels, usernames, tiny notes to future-you, and many other things that are definitely not numbers. This Block introduces strings, Python's basic way to represent text. You will learn how quotes work, how to store text in variables, how to print strings, and why a value like "25" is text while 25 is a number.
What you will learn:
print(name) and print("name")""Plain examples first, light theory second. By the end, you will understand the tiny quote marks that make Python treat something as text. Small marks, big responsibility.
Ready to practice this in the browser?
> Play now