Today we will learn about String Function and String Indexing in Python. String Function Python provides built-in functions to modify text: upper() – uppercase lower() – lowercase title() – capitalize each word strip() – remove spaces (both sides) rstrip() – remove right spaces lstrip() – remove left spaces String Indexing String indexing allows us to access characters by position. Starts from 0 Negative indexing starts from -1 Example: text = "Python" print(text[0]) # P print(text[-1]) # n #Python #PythonProgramming #LearnPython #Coding #Programming #Developers #CodeNewbie #TechEducation #ComputerScience #100DaysOfCode #CodingJourney #AI #DataScience

This is a great overview of string functions in Python. Learning to manipulate strings is essential for any developer.

To view or add a comment, sign in

Explore content categories