Skip to main content
Brave Programmer Logo

BraveProgrammer

BraveProgrammer

HomeProjectsBlogsCoursesLessonsAbout

Site footer

BraveProgrammer

Free coding courses, practical tutorials, and real projects from BraveProgrammer. Learn web development with React, Next.js, and TypeScript.

Navigation

  • Home
  • Projects
  • Blogs
  • Courses

Resources

  • About
  • Lessons

© 2026 BraveProgrammer. All rights reserved.

  1. Courses
  2. /
  3. Python Fundamentals

Lesson 18 of 55 · Python

String Manipulation

Duration: 20 minutes

String Manipulation\n\nStrings are immutable sequences of Unicode characters. Python offers powerful slicing, formatting, and a rich set of methods.\n\npython\nmsg = 'Hello, World!'\nprint(msg.upper()) # HELLO, WORLD!\nprint(msg[7:12]) # World\n\n# f‑strings (Python 3.6+) for clean interpolation\nname = 'Alice'\nprint(f'Hi, {name}!')\n\n\nBecause strings are immutable, operations like upper() return a new string rather than modifying the original.\n

Previous: Data Structures – DictionariesNext: File I/O