367,035 views
14 votes
14 votes
Pseudo code……………………………………………………,,,,,,..,,

Pseudo code……………………………………………………,,,,,,..,,-example-1
User Mattia Surricchio
by
2.9k points

1 Answer

26 votes
26 votes

Answer:

# Initialize the height of the ball to 100 feet

height = 100

# Initialize a counter for the number of bounces

bounces = 0

# Loop until the height of the ball is less than or equal to 5 feet

while height > 5:

# Calculate the new height of the ball by multiplying the previous height by 0.9

height = height * 0.9

# Increment the number of bounces

bounces = bounces + 1

# Return the number of bounces

return bounces

User Sandra Schlichting
by
2.5k points