Briefle words · Code & architecture
Composed method
A function made of a few calls to other well-named functions, so it reads like a short list of steps.
Say it to an AI
Python confirm_booking(booking) as a composed method at a single level of abstraction: validate, price_trip, charge_card, send_confirmation_email, then set status. Put the email rendering and sending in its own function using our template and mailer, no SMTP or HTML inline.
How an expert would brief the stronger version of “Confirm a booking”.
See it
Try it as a puzzle →A travel-booking API confirms a multi-leg trip once the traveller pays.
Why: B's 'confirm_booking' is five lines, and each one names a single step of confirming a trip.
Related words
Room 3 · Functions & structure
Learn “Composed method” in a five-minute lesson