Strings in Python
Strings are one of the most common data types in Python – they represent text, like words, sentences, or even whole stories!
In Python, strings are easy to create and work with. Let’s explore them step by step with simple examples you can try right away.
Creating Strings
You can create strings with single quotes, double quotes, or triple quotes (for multi-line strings).
Concatenation – Joining Strings
Use the + operator to join strings together.
Repetition
Multiply a string with * to repeat it.
Indexing and Slicing
Strings are sequences – you can access characters by position (index starts at 0).
Strings Are Immutable
You cannot change individual characters in a string – it's immutable.
String Length
Quick Quiz
We have reviewed and checked the materials, but errors may still occur. The content is provided for educational purposes only, so use it at your own responsibility and verify with other sources if needed.
✨ Ask Lara — your AI study partner
Unlock personalized learning support. Lara can explain lessons, summarize topics, and answer your study questions — available from the Go plan and above.
Lara helps you learn faster — exclusive to ReadyTools Go, Plus, and Max members.

