Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Repetition-while 122b-48ab-be3e-c1b7c2c18ad6/do/ad28eae2-83ff-4435-b8d1-1be68420809b Repetition - while Given a series of numbers as input, add them up until the input is 10 and print the total Do

Repetition-while
image text in transcribed
image text in transcribed
image text in transcribed
122b-48ab-be3e-c1b7c2c18ad6/do/ad28eae2-83ff-4435-b8d1-1be68420809b Repetition - while Given a series of numbers as input, add them up until the input is 10 and print the total Do not add the final 10. For example, if the following numbers are input 10 The output should be Hint When you don't know the number of repetitions, always use while loop code.py o NewFull Screen Automated Results 1 totale 2 while True: 3 number int (input("please enter a 4 if number10: break else: total total+number 8 print(total) apter 02/Re X e https//class.mimir io/assignments/20689abe-122b-48ab-be3e-c1b7c2c18ad6/do/ad28 Repetition - while code.py@ + New 1 total=0 2 while True: 3 4 5 6 else: 7 8 print (total)l number int (input ("please enter a number: ")) if number == 10: break total = total + number | Exerases Chapter 02/Re A https://dassminirso & Submit Hint When you don't know the number of repetions, always use while loo Debugging Information for Test 2 O THE CORRECT OUTPUT OF THE TEST CASE Input an int: Input an int: Input an int: Input an int: Input an int: Input an int: Input an int: Input an int:n PRETTY DIFF This diff is colored to make it clear what parts of the output are wrong Gireen ndcaltes things in the comect outpiut that you ae msing indicates things in your output that shouldnt be there The. character refers to newines, so the green & character reters a need to remove from your output newine you are missing in your output and the redeter to eine you

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_2

Step: 3

blur-text-image_3

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

Machine Learning And Knowledge Discovery In Databases European Conference Ecml Pkdd 2014 Nancy France September 15 19 2014 Proceedings Part I Lnai 8724

Authors: Toon Calders ,Floriana Esposito ,Eyke Hullermeier ,Rosa Meo

2014th Edition

3662448475, 978-3662448472

More Books

Students also viewed these Databases questions