Strings (str)

Strings are immutable sequences of characters.
They are used to represent text and are defined using single quotes (') or double quotes (").
Triple quotes (''' or """) can also be used for multiline strings.

name = "Ana"
message = 'Hello, world'
paragraph = """This is a
multiline text."""

Strings support indexing and slicing:

greeting = "Hello"
print(greeting[0])    # H
print(greeting[1:3])  # el

They can also be concatenated and formatted:

# Concatenation
full_name = "John" + " " + "Smith"

# Modern formatting (f-strings)
age = 25
print(f"Hi, I am {age} years old")