bugl
bugl
HomeLearnPatternsPathsSearchPremium
HomeLearnPatternsPaths

Loading lesson path

Learn/Python/Foundations
Python•Foundations

Python - Modify Strings

Python has a set of built-in methods that you can use on strings.

Upper Case

upper()

Lower Case

lower()

Remove Whitespace

Whitespace is the space before and/or after the actual text, and very often you want to remove this space.

strip()

Replace String

replace()

Split String

The split() method returns a list where the text between the specified separator becomes the list items.

split()

Learn more about Lists in our Python Lists chapter.

String Methods

Learn more about String Methods with our String Methods Reference

Previous

Python - Slicing Strings

Next

Python - String Concatenation