Syntax and Types

2. Syntax and Types#

This chapter builds the basic vocabulary of Python programs: names, values, operators, built-in functions, and types.

  • Variables and assignment

  • Operators and expressions

  • Built-in functions

  • Basic scalar types

  • Collection type overview

Video

This overview introduces numeric data, arithmetic operators, comparisons, and basic type conversion.

Learning Goals

By the end of this chapter, you will be able to:

  1. Create and name variables using Python assignment syntax

  2. Use arithmetic, comparison, logical, and assignment operators

  3. Classify values by built-in type

  4. Use common built-in functions to inspect and transform values

  5. Choose appropriate basic and collection types for simple data

Chapter Flow

Chapter Overview Slides