returnEasy Playground

Exits a function and optionally sends a value back to the caller

Python Playground
Output
Click "Run" to execute your code

return sends a value back to the caller and exits the function immediately. Without return, a function returns None.

Challenge

Try modifying the code above to explore different behaviors. Can you extend the example to handle a new use case?