subject

Python Exercise 5 grade 10 1. Develop a program that asks user to enter a list of integers, using zero as a signal of termination.
The program should calculate the number times that consecutive numbers are equal.
Ex: The following input
3
4
4
6
7
7
7
8
9
9
0
Should give you an answer of 4

2. Write a program that finds the largest in a series of numbers entered by the user. The program
must prompt the user to enter numbers one by one. When the user enters 0 or a negative
number, the program must display the largest nonnegative number entered:
Enter a number: 60
Enter a number: 38.3
Enter a number: 4.89
Enter a number: 100.62
Enter a number: 75.2295
Enter a number: 0
The largest number entered was 100.62
Notice that the numbers aren’t necessarily integers

Name: Python Exercise 5
3. Write a program that displays a number with its digit reversed. Generalize the program so that
the number can be one, two, or three digits. The program stops when users enters 0
Enter a number: 123
The reversed digit is: 321
Enter a number: 1
The reversed digit is: 1
Enter a number: 34
The reversed digit is: 43
Enter a number: 0

ansver
Answers: 3

Other questions on the subject: Computers and Technology

image
Computers and Technology, 21.06.2019 19:30, LuxTheGirl3070
Entering key dates from your course syllabi test and quiz dates, assignments due dates in your planner can you manage your schedule by allowing you to see commitments ahead of time.
Answers: 3
image
Computers and Technology, 22.06.2019 10:00, ozzy55
Create a word problem that involves calculating the volume and surface area of a three-dimensional object. cube: surface area 6 s2 , volume s3
Answers: 3
image
Computers and Technology, 24.06.2019 14:30, tleppek6245
Alison is having a hard time at work because hee inbox is flooded with emails every day. some of these emails are unsolicited. some of other she don’t need. which action should she take to better manager her emails?
Answers: 1
image
Computers and Technology, 24.06.2019 15:00, MilanPatel
In excel, what happens to the cell contents when you click and drag a cell into multiple cells?
Answers: 1
You know the right answer?
Python Exercise 5 grade 10 1. Develop a program that asks user to enter a list of integers, using z...

Questions in other subjects:

Konu
Mathematics, 23.12.2019 17:31