AI engineering glossary · Python core

What is string?

String (also called str): An immutable sequence of characters of type str, written in single, double or triple quotes. Strings hold text such as names, messages and file paths, and support indexing, slicing and many built-in methods for searching and changing case.

Level: beginnerTopic: Python core

String: an example

name = 'Asha' has length 4, and name[0] is 'A'. name.upper() returns a new string 'ASHA'.

Related terms

More Python core terms

Where you learn it

String is part of the AI Engineering Program, which teaches it with notes, a hands-on lab and an exam. The first lesson is free.

Before you go

Take the cheat sheet with you

One free PDF: the key AI-engineering terms, formulas and Python idioms. No spam; unsubscribe any time.