1/21
Vocabulary flashcards covering core concepts of Python functions, module dot notation, flow of execution, function classifications, and design recipes.
Name | Mastery | Learn | Test | Matching | Spaced | Call with Kai | Chat |
|---|
No analytics yet
Send a link to your students to track their progress
Function
A named sequence of statements that performs a computation.
Argument
The value passed into a function inside parentheses during a function call, which can be a literal, a variable, or an expression.
Return Value
The value that comes back out of a function call and takes the place of the call in an expression.
max()
A built-in function that returns the largest value among its arguments or within a sequence.
min()
A built-in function that returns the smallest value among its arguments or within a sequence.
len()
A built-in function that returns the total number of items or characters in its argument.
Type Conversion Functions
Built-in functions such as int(), float(), and str() that take a value of one type and return a new value of a different type without modifying the original value.
Truncation
The process performed by int() on float values where the fractional part is chopped off toward zero rather than rounded.
Module
A file containing related functions and variables that can be imported and used in a program.
Dot Notation
The syntax used to access functions or variables inside an imported module by writing the module name, followed by a dot, and then the function or variable name.
def Keyword
The Python keyword used to define a new user-made function.
Function Object
The object created in memory when a function definition statement is executed, which the function's name references.
Flow of Execution
The order in which program statements are executed, proceeding top-to-bottom, where function calls act as detours rather than permanent jumps.
Parameter
The variable name listed inside a function definition's parentheses that refers to the argument value handed into the function.
Local Variable
A variable defined inside a function body that is private to that function, created when called and destroyed upon return.
Fruitful Function
A function that explicitly hands back a value using a return statement.
Void Function
A function that performs an action (such as printing to the screen or writing to a file) but does not return a meaningful value, returning None instead.
None
A unique value of type NoneType used by Python to indicate the absence of a value, such as what is returned by a void function.
Decomposition
The practice of breaking a large program down into smaller, manageable function components.
Design Recipe
A six-field documentation template (Purpose, Parameters, Returns, Effects, Example, Assumption) written before a function body to describe what it does.
Effects (Design Recipe)
The field in a design recipe that documents external changes a function causes outside itself, such as printing output or altering a file.
Example (Design Recipe)
The field in a design recipe showing an actual call to the function alongside its precise expected return value.