© Irv Kalb 2018
Irv KalbLearn to Program with Python 3https://doi.org/10.1007/978-1-4842-3879-0_4

4. User-Defined Functions

Irv Kalb1 
Mountain View, California, USA

Software is a detailed set of instructions that tell the computer what to do. There are numerous examples where we, as humans, follow a set of such instructions. As a simple example, many pieces of furniture from IKEA come with a set of high-level instructions in the form of pictures. When creating these instructions, the people at IKEA assume a certain level of basic knowledge of how to use tools, such as a wrench, a screwdriver, a hammer, and so on.

But using tools could be broken down into simpler steps. Using a hammer could be broken down into grip the hammer by the handle, hold ...

Get Learn to Program with Python 3: A Step-by-Step Guide to Programming now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.