Flow controls: Loops · 16 / 26 Exercise Easy

While loop with validated input

Objective

Create a Python program that requests a number (x) and displays the result of multiplying that number by 10. The program should repeat using the while statement until a negative number is entered. When a negative number is entered, the program will stop.

Input
5
4
6
-1
Output
50
40
60

Open the editor in full screen: the statement on the left and your code, the output and the tests on the right.

Start exercise