Question: Modify the sentinel . py program to use a priming and a modification read ( see the Application: Processing Sentinel Values section ) . The

Modify the sentinel. py program to use a priming and a modification read (see the "Application: Processing Sentinel Values"
section). The program should achieve the same result of computing an average salary and use a sentinel value of -1.
# Initialize variables to maintain the running total and count.
total =0.0
count =
# Process data until the sentinel is entered.
# Your code goes here
while salary 0.0 :
# Your code goes here
# Compute and print the average salary
if count >0 :
average = total ?? count
print("Average salary is", average)
else :
print("No data was entered.")
View your last submission ,
 Modify the sentinel. py program to use a priming and a

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!