Challenge
Docstring and type hints
Add a docstring to fuel_needed() that says what it returns and what the reserve means, then add type hints for its parameters and return value; the tests read both from the function itself.
3 results
Challenge
Add a docstring to fuel_needed() that says what it returns and what the reserve means, then add type hints for its parameters and return value; the tests read both from the function itself.
Example
Docstrings describe what a function does. Good programming practice.
Example
How to write comments in Python. Comments help other programmers understand your code.