CJCoding With Joseph
15free / daySign inCreate account

Count Down By Steps

Write the body of count_down_by(start: int, step: int) -> None so it prints start, then start minus step, and keeps subtracting step while the value is still above 0, one number per line; nothing is printed when start is 0 or less. The driver reads the two integers, calls the function and prints Done afterwards; leave the driver alone. Input: two lines, the start then the step, no prompts.

Expected Output:

10
7
4
1
Done

= newline. The output ends with a newline — print one after the last line.

Hints3 available
Topics:
Functions
📥 Auto-Input:
10\n3\n
This input is automatically fed to your program's stdin
1
Tab to indent (Esc then Tab to move on) · Ctrl+Enter to run · Ctrl+Space to expand shortcuts (pr, inp, def)

Your Output

Run your code to see the output here...

Test Cases

Run your code to see test case results.