PYTHON CORE · LESSON 47
Two inputs to function
A few arguments · about 11 minutes
Learning with progressRead the summary for free. To save the work, log in to the account.
Type the code yourself
Reprint the function with two inputs and its call.
def multiply(a, b):
return a * b
print(multiply(2, 4))Open the editor for class workSolve it yourself
Create add with a and b arguments. Return their amount, then call add with 2 and 3 and output the answer.
The answer is hidden. Use similar examples from the lesson notes.
Opening up your homework