Makerlab Juniors - Step Count for a Healthy Life

View as PDF

Submit solution

Points: 6
Time limit: 1.0s
Memory limit: 16M

Author:
Problem types
Allowed languages
Blockly, C, C++, Java, Pascal, Python
Step Count for a Healthy Life

A smart step counter calculates whether you've achieved your goal for a healthy lifestyle. The goal is 10.000 steps per day. If you've walked fewer than 10.000 steps, the counter calculates how many steps you're missing. If you've walked 10.000 or more, it tells you how many extra steps you took!

Write an algorithm that:

Asks the user for the number of steps they took today.

Checks: If it's fewer than 10.000, calculates and displays how many steps you need to reach your goal.

Otherwise, calculates and displays how many extra steps you took beyond your goal.

Examples

input

8000

output

2000

input

10200

output

200

Comments