Мой профиль
ACTIVITY 11 / 50

The program asks

Try as many times as you need

Let’s understand

input reads one line from the input box. Even a typed digit starts as text. int converts a whole-number string to a number; use float for decimals. Enter input values in the panel on the right before running, one per line.

Listen to the explanation

Example

count = int(input())
print(count * 2)
YOUR MISSION

Read a number with int(input()), add 2 and print the result. Input 5 should produce 7.

I need a hint

Save the number in a variable, then calculate with it.

How to find an error
  1. Read the last line of the error message.
  2. Find the indicated line. Check quotes, parentheses and indentation.
  3. Change one thing and run again.

main.py

4 spaces

Your draft stays in this browser.

Result

Python
Your program’s output will appear here. Click Run.