Python Fundamentals
Learning Path ⋅ Skills: Core Python 3, Python Syntax
This Python beginner learning path is designed to guide you through the essentials of Python programming, starting from the basics and progressing towards more advanced concepts.
Note: If you’re completely new to programming, then it’s best to start with the course-based, guided Python Basics: Introduction to Python learning path instead.
Whether you’re still relatively new to programming or looking to add Python to your skill set, this path offers a comprehensive approach to make progress in your Python learning journey. Through a combination of tutorials, courses, and interactive quizzes, you’ll build a strong foundation in Python that will prepare you for more complex programming tasks and projects.
What You’ll Learn:
- The fundamentals of Python, including its history and why it’s a popular choice
- How to install and set up Python on your computer
- Basic data types, variables, operators, and expressions
- String manipulation, list and tuple operations, and working with dictionaries and sets
- Control flow using conditional statements and loops
- Writing and using functions, understanding namespaces, and file handling
- Working with regular expressions, managing packages with pip, and debugging with tracebacks
Python Fundamentals
Learning Path ⋅ 30 Resources
Tutorial
Why Choose Python 3
An overview of the Python programming language, including a brief history of the development of Python and reasons why you might select Python as your language of choice.
Course
Installing Python 3
To get started working with Python, you'll need to have access to the Python interpreter. There are several common ways to accomplish this and in this course, you will learn how to install the latest version of Python on your computer.
Tutorial
Interacting With Python
How to actually execute Python code and run Python programs using the CPython REPL, executing script files, and integrated development environments.
Course
11 Beginner Tips for Learning Python
See several learning strategies and tips that will help you jumpstart your journey towards becoming a rockstar Python programmer!
Course
Basic Data Types in Python
Learn the basic data types that are built into Python, like numbers, strings, and Booleans. You'll also get an overview of Python's built-in functions.
Interactive Quiz
Basic Data Types Quiz
Course
Variables in Python
Learn how every item of data in a Python program can be described by the abstract term "object," and how to manipulate objects using symbolic names called "variables."
Interactive Quiz
Python Variables Quiz
Free Email Class
"Python Tricks" Email Series
Get a short & sweet Python Trick delivered to your inbox every couple of days.
Tutorial
Operators and Expressions in Python
In Python, operators are special symbols, combinations of symbols, or keywords that designate some type of computation. You can combine objects and operators to build expressions that perform the actual computation. So, operators are the building blocks of expressions.
Interactive Quiz
Python Operators and Expressions Quiz
Course
Strings and Character Data in Python
Learn how to use Python's rich set of operators, functions, and methods for working with strings. You'll learn how to access and extract portions of strings, and also become familiar with the methods that are available to manipulate and modify string data in Python 3.
Interactive Quiz
Python Strings Quiz
Course
Lists and Tuples in Python
See the important characteristics of lists and tuples in Python 3. You'll learn how to define them and how to manipulate them. When you're finished, you'll have a good feel for when and how to use these object types in a Python program.
Interactive Quiz
Lists & Tuples Quiz
Course
Dictionaries in Python
In this course on Python dictionaries, you'll cover the basic characteristics of dictionaries and learn how to access and manage dictionary data. Once you've finished this course, you'll have a good sense of when a dictionary is the appropriate data type to use and know how to use it.
Interactive Quiz
Dictionaries Quiz
Course
Sets in Python
Learn how to work with Python's set data type. You'll see how to define set objects in Python and discover the operations that they support. By the end of this course, you'll have a good feel for when a set is an appropriate choice in your own programs.
Interactive Quiz
Sets Quiz
Tutorial
Python Program Lexical Structure
In this tutorial you'll dig deeper into Python's lexical structure and start arranging code into more complex groupings. You'll learn about the syntactic elements that comprise statements, the basic units that make up a Python program.
Interactive Quiz
Python Program Structure Quiz
Course
Conditional Statements in Python (if/elif/else)
Learn how to work with conditional ("if") statements in Python. Master if-statements step-by-step and see how to write complex decision making code in your programs.
Interactive Quiz
Conditional Statements Quiz
Course
"while" Loops in Python (Indefinite Iteration)
Master indefinite iteration using the Python "while" loop. You’ll be able to construct basic and complex while loops, interrupt loop execution with break and continue, use the else clause with a while loop, and deal with infinite loops.
Interactive Quiz
While Loops Quiz
Course
"for" Loops in Python (Definite Iteration)
Learn all about how to perform definite iteration with Python "for" loops. You’ll see how other programming languages implement definite iteration, learn about iterables and iterators, and tie it all together to learn about Python’s for loop.
Course
Understanding Python List Comprehensions
Python list comprehensions make it easy to create lists while performing sophisticated filtering, mapping, and conditional logic on their members. In this course, you'll learn when to use a list comprehension in Python and how to create them effectively.
Course
Python Booleans: Leveraging the Values of Truth
Learn about the built-in Python Boolean data type, which is used to represent the truth value of an expression. You'll see how to use Booleans to compare values, check for identity and membership, and control the flow of your programs with conditionals.
Course
Reading Input and Writing Output in Python
In this introductory Python course, you'll learn how to take user input from the keyboard with the built-in function input() and how to display output to the console with the built-in function print().
Course
The Python print() Function: Go Beyond the Basics
Learn about the print() function in Python and discover some of its lesser-known features. Avoid common mistakes, take your "hello world" to the next level, and know when to use a better alternative.
Course
Formatting Python Strings
See two items to add to your Python string formatting toolkit. You'll learn about Python's string format method and the formatted string literal, or f-string. You'll learn about these formatting techniques in detail and add them to your Python string formatting toolkit.
Course
Defining and Calling Python Functions
Learn how to define and call your own Python function. You'll also learn about passing data to your function and returning data from your function back to its calling environment.
Course
Using the Python return Statement Effectively
Learn how to use the Python return statement when writing functions. Additionally, you'll cover some good programming practices related to the use of return. With this knowledge, you'll be able to write readable, robust, and maintainable functions in Python.
Course
Regular Expressions (Part 1)
Learn how to perform more complex string pattern matching using regular expressions, or regexes, in Python. You'll also explore more advanced regex tools and techniques that are available in Python.
Tutorial
Regular Expressions (Part 2)
In the previous tutorial in this series, you learned how to perform sophisticated pattern matching using regular expressions, or regexes, in Python. This tutorial explores more regex tools and techniques that are available in Python.
Course
Navigating Namespaces and Scope in Python
Learn about Python namespaces, the structures used to store and organize the symbolic names created during execution of a Python program. You'll learn when namespaces are created, how they are implemented, and how they define variable scope.
Course
Reading and Writing Files in Python
Learn about reading and writing files in Python. You'll cover everything from what a file is made up of to which libraries can help you along that way. You'll also take a look at some basic scenarios of file usage as well as some advanced techniques.
Course
Getting the Most Out of a Python Traceback
Learn how to read and understand the information you can get from a Python stack traceback. You'll walk through several examples and see some of the most common tracebacks in Python.
Course
A Beginner's Guide to pip
What is pip? In this beginner-friendly course, you'll learn how to use pip, the standard package manager for Python, so that you can install and manage additional packages that are not part of the Python standard library.
Learning Path
Continue Your Python Journey With "Python Basics"
Your complete Python curriculum—with exercises, interactive quizzes, and sample projects.
Got feedback on this learning path?
Looking for real-time conversation? Visit the Real Python Community Chat or join the next “Office Hours” Live Q&A Session. Happy Pythoning!