Skip to main content

Computer ScienceFor 6th gradeProcedures and functions

Function machine

Pick what the function does, then call it with different arguments and see what it returns.

Function body
Argument
3
Return value
6

f(3) returns 6: the parameter x takes the argument, and the body doubles it.

Used in