# Enum

say it: **“EE-num”** **/ˈinəm/**

A fixed set of named choices, like order statuses.

## What is an **enum**?

An **enum** is a fixed set of named choices, like order statuses, so you can't mistype one as a string.

```python
from enum import Enum

class OrderStatus(Enum):
    PENDING = "pending"
    SHIPPED = "shipped"
    DELIVERED = "delivered"

status = OrderStatus.SHIPPED
print(status.value)  # shipped
```

Level: Freelancer · [More Python terms at this level](https://www.ask-codey.com/glossary?category=python&level=4)

Updated: November 17, 2026

## In other subjects

- [enum in C#](https://www.ask-codey.com/glossary/enum-c-sharp)
- [enum in Java](https://www.ask-codey.com/glossary/enum-java)

Source: https://www.ask-codey.com/glossary/enum
