December 2017
Beginner
412 pages
10h 8m
English
Python comes with many built-in functions that perform common operations. One example is abs, which produces the absolute value of a number:
| | >>> abs(-9) |
| | 9 |
| | >>> abs(3.3) |
| | 3.3 |
Each of these statements is a function call.
The general form of a function call is as follows:
| | function_name(arguments) |
An argument is an expression that appears between the parentheses of a function call. In abs(-9), the argument is -9.
Here, we calculate the difference between a day temperature and a night temperature, as might ...
Read now
Unlock full access