Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Need help writing this program in Python. Write a program with a loop that asks the user to enter a series of positive numbers. The

Need help writing this program in Python.
Write a program with a loop that asks the user to enter a series of positive numbers. The user should enter a negative number, -99, to signal the end of the series. After all the positive numbers have been entered, the program should display their sum. But when a negative number is entered, the program should display a phrase like The number should be positive or -99 to quit!
image text in transcribed
Enter a positive number (negative 99 to quit): 9 Enter a positive number (negative 99 to quit): -3 The number should be positive or -99 to quit! Enter a positive number (negative 99 to quit): 8 Enter a positive number (negative 99 to quit): -99 Total = 17.00

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Basics Computer EngineeringInformation Warehouse Basics From Science

Authors: Odiljon Jakbarov ,Anvarkhan Majidov

1st Edition

620675183X, 978-6206751830

More Books

Students also viewed these Databases questions

Question

Why is converging evidence important?

Answered: 1 week ago

Question

3. Outline the four major approaches to informative speeches

Answered: 1 week ago

Question

4. Employ strategies to make your audience hungry for information

Answered: 1 week ago