CodeX
Published in

CodeX

10 Python One-Liners for Strings

Photo by Aditya Wardhana on Unsplash

Background on Strings

Functionally, strings can represent just about anything that can be encoded as text or bytes. Python’s strings serve the same role as character arrays in languages such as C but they are a higher-level tool than arrays. They are classified as immutable sequences, meaning characters within have a left-to-right positional order and that they cannot be changed in place. Note…

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store