114k views
1 vote
Pseudo code……………………………………………………,,,,,,..,,

Pseudo code……………………………………………………,,,,,,..,,-example-1
User Jake W
by
8.0k points

1 Answer

6 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 Wookie
by
8.0k points

No related questions found

Welcome to QAmmunity.org, where you can ask questions and receive answers from other members of our community.