Exploring Tuples in Python

Beginner
6m
293
5/5

In this lesson, we’ll explore tuple objects a bit closer and we’ll cover the ways to create and use tuples. This lesson is part of a series of content designed to help you learn to program with the Python programming language.

Learning Objectives

  • Tuples are a special type of collection used to store a small number of related objects
  • Tuples cannot be changed once they’re created
  • Tuples can be created by:
    • Passing a collection to the built-in tuple function
    • Using the parentheses shorthand syntax with each object separated with a comma
  • Tuples can be automatically unpacked into name bindings by specifying the same amount of names as objects

Intended Audience

This lesson was designed for first-time developers wanting to learn Python. 

Prerequisites 

This is an introductory lesson and doesn’t require any prior programming knowledge.

About the Author
Avatar
Ben Lambert
Software Engineer
Students
109,319
Labs
37
Courses
50
Learning paths
58

Ben Lambert is a software engineer and was previously the lead author for DevOps and Microsoft Azure training content at Cloud Academy. His courses and learning paths covered Cloud Ecosystem technologies such as DC/OS, configuration management tools, and containers. As a software engineer, Ben’s experience includes building highly available web and mobile apps. When he’s not building software, he’s hiking, camping, or creating video games.

Covered Topics