print() Function: Go Beyond the Basics - Basic Usage; String Formatting Styles; sep, end, and flush @realpython
print() Function: Go Beyond the Basics - Basic Usage; String Formatting Styles; sep, end, and flush  @realpython
Uploaded August 2026 | Updated December 2026, 2 days ago
Download your free Python Cheat Sheet here: realpython.com/cheatsheet
Free Python Skill Test with instant level + learning plan: realpython.com/skill-test
Want to learn faster? Become a Python Expert with unlimited access to 5,000+ tutorials, videos, and exercises: realpython.com/start


Free print() sample code → realpython.com/bonus/python-print-code

This is a preview of the video course, "The Python print() Function: Go Beyond the Basics". If you’re like most Python users, including us, then you probably started your Python journey by learning about print(). It helped you write your very own Hello World one-liner. You can use it to display formatted messages onto the screen and perhaps find some bugs. But if you think that’s all there is to know about Python’s print(), then you’re missing out on a lot!

Keep reading to take full advantage of this underappreciated little function. This course will get you up to speed with using Python print() effectively. Prepare for a deep dive as you go through the sections. You may be surprised how much print() has to offer!

This is a portion of the complete course, which you can find here: realpython.com/courses/python-print

And the original text tutorial is here: realpython.com/python-print

The rest of the course covers:
- Exercise: Print a Row as CSV
- Printing to File Streams
- Exercise: Print Lines to a File
- Custom Data Types
- Exercise: Customize How an Object Prints
- Python 2's print vs Python 3's print()
- Pretty Print
- ANSI Escape Sequences
- Simple Animation
- Mocking print() in Unit Tests
- Debugging via print()
- The Python print() Function (Quiz)


🐍 Become a Python expert with real-world tutorials, on-demand courses, interactive quizzes, and 24/7 access to a community of experts at realpython.com

▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰
🐍 Start Here → realpython.com/start
🗺️ Guided Learning Paths → realpython.com/learning-paths
🎧 Real Python Podcast → realpython.com/podcast

📚 Python Books → realpython.com/books
📖 Python Reference → realpython.com/ref
🧑‍💻 Quizzes & Exercises → realpython.com/quizzes

🎓 Live Courses: realpython.com/live
⭐️ Reviews & Learner Stories: realpython.com/learner-stories
▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰
print() Function: Go Beyond the Basics - Basic Usage; String Formatting Styles; sep, end, and flushConvince Your Boss That Performance MattersGit for Beginners: Your First Repo in 6 MinutesWagtail CMS: What It Adds on Top of DjangoSending and Fetching Email Use Different ProtocolsThe Registry Pattern: Cleaner Python Than if-elifMeet Mentor AI – Your New Python & AI Learning GuideMake Claude Code Explain Your Code VisuallyOffset AI Brain Drain With a Personal Bootcamp!Python Without the GIL: Why There Are Now More LocksNew PyPI Rule That Protects Old ReleasesWhy Python Uses _Single and  Double Underscores
Real Python |

print() Function: Go Beyond the Basics - Basic Usage; String Formatting Styles; sep, end, and flush

SHARE TO X SHARE TO REDDIT SHARE TO FACEBOOK WALLPAPER