A teacher adjusts quiz scores with the Python program below. Students who scored 50 or more receive 10 bonus points, and everyone else receives 25 bonus points.
score = int(input("Score: ")) if score >= 50: score = score + 10 else: score = score + 25 print(score)
Give the number printed for each of the three inputs below, as a whole number.
Unlock full course notes by signing up
Following the shared continuation
A ticket system runs the following Python code. Select every true statement about which instructions execute and what the system displays.
Tracing a shipping decision in order
An online store uses the Python program below to work out what a customer owes. Orders of 50 dollars or more ship free; smaller orders pay a flat shipping charge.
A customer enters 42.50. Put the events of this run in the order the computer carries them out.
Finding an erased decision result
An event venue charges 12 dollars for every registered attendee above its included capacity. The programmer writes the Python code below. Calculate the invoice produced by the original code, then the invoice after deleting only the unindented extra_attendees = 0 line immediately before the invoice calculation. Give both amounts in dollars to two decimal places.