Skip to content

Glossary: Coding with AI Assistants

extract a function

Also written: extracting a function

A refactoring step that moves repeated code into a new, named function, like `format_line` in `receipt.py`.

Where the book teaches it

Related terms

Refactoring