Introduction to Python

Learning PathSkills: Core Python 3, Python Syntax

Python Basics

Learn fundamental concepts for Python beginners that will help you get started on your journey to learn Python. These tutorials focus on the absolutely essential things you need to know about Python.

What You’ll Learn:

  • Installing a Python environment
  • The basics of the Python language

Introduction to Python

Learning Path ⋅ 30 Resources

Introduction to Python 3

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.

#1
Python 3 Installation & Setup Guide

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.

#2
Interacting With Python

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.

#3
Beginner Tips for Learning Python

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!

#4
Basic Data Types in Python

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.

#5
Python Basics

Interactive Quiz

Basic Data Types Quiz

Variables in Python

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."

#6
Python Basics

Interactive Quiz

Python Variables Quiz

Python Tricks

Free Email Class

"Python Tricks" Email Series

Get a short & sweet Python Trick delivered to your inbox every couple of days.

#7
Operators and Expressions in Python

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.

#8
Core Python Tutorials Artwork

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.

#9
Python Basics

Interactive Quiz

Python Strings Quiz

Lists and Tuples in Python

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.

#10
Python Basics

Interactive Quiz

Lists & Tuples Quiz

How to Iterate Through a Dictionary in Python

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.

#11
Python Basics

Interactive Quiz

Dictionaries Quiz

Sets in Python

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.

#12
Python Basics

Interactive Quiz

Sets Quiz

Python Program Lexical Structure

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.

#13
Conditional Statements in Python

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.

#14
Python Basics

Interactive Quiz

Conditional Statements Quiz

Python "while" Loops (Indefinite Iteration)

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.

#15
Python Basics

Interactive Quiz

While Loops Quiz

Python "for" Loops (Definite Iteration)

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.

#16
When to Use a List Comprehension in Python

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.

#17
Python Booleans: Optimize Your Code With Truth Values

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.

#18
Basic Input, Output, and String Formatting in Python

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().

#19
The Ultimate Guide to Python 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.

#20
A Guide to the Newer Python String Format Techniques

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.

#21
Defining Your Own Python Function

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.

#22
The Python return Statement: Usage and Best Practices

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.

#23
Regular Expressions: Regexes in Python (Part 1)

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.

#24
Regular Expressions: Regexes in Python (Part 2)

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.

#25
Namespaces and Scope 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.

#26
Reading and Writing Files in Python (Guide)

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.

#27
Understanding the Python Traceback

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.

#28
What Is pip? A Guide for New Pythonistas

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.

#29
Python Basics Book

Learning Path

Continue Your Python Journey With "Python Basics"

Your complete Python curriculum—with exercises, interactive quizzes, and sample projects.

#30

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!

« Browse All Learning Paths