๐Ÿ› ๏ธBuilding Closure-Based UtilitiesWORKSHOP
1
2
3
4
5

Step 1

Write a `make_counter()` function that returns a tuple of two functions: `increment` and `reset`. `increment` should increase an internal count by 1 and return it. `reset` should set the count back to 0. Use `nonlocal` to modify the shared state.

โŒ˜ Enter (Mac) ยท Ctrl+Enter (Win/Linux)