Module 2 · Python literals · Lesson 4 of 6
Strings
A string — type str — is text: a sequence of characters wrapped in quotes. You've used them since your first print.
Single quotes ('...') and double quotes ("...") both work — just open and close with the same kind. A handy rule of thumb: use double quotes when your text itself contains an apostrophe, so it doesn't end the string early.
Anything inside quotes is text, even digits: "123" is a string, not the number 123. They look the same on screen but Python treats them very differently — you can do maths with one and not the other. Try a few things:
Notice + joins strings together and * repeats one — the same symbols mean something different for text than for numbers. Last of the four: true and false.