Skip to main content

functools - Functional Superpowers

partial - Pre-fill Function Arguments

0:00
LearnStep 1/4

What is partial?

Partial Functions: Freeze Some Arguments

partial creates a new function with some arguments pre-filled:

python

Real-World Example: Logging

python