Question: in Python, how do I get each question to repeat itself if the user enters a number greater or equal to 100? i want that

in Python, how do I get each question to repeat itself if the user enters a number greater or equal to 100? i want that to be unacceptable and the original question asked again for each individual case.

while True: bp=int(input('How many bench press reps did you perform?: ')) if bp >= 100: print('Please enter a number less than 100. You are overtraining!') bp=int(input('How many bench press reps did you perform?: ')) else: break bs=int(input('How many back squat reps did you perform?: ')) if bs>= 100: print('Please enter a number less than 100. You are overtraining!') bs=int(input('How many back squat reps did you perform?: ')) else: break mp=int(input('How many military press reps did you perform?: ')) if mp>=100: print('Please enter a number less than 100. You are overtraining!') mp=int(input('How many military press reps did you perform?: ')) else: break dl=int(input('How many deadlifts did you perform?: ')) if dl>=100: print('Please enter a number less than 100. You are overtraining!') dl=int(input('How many deadlifts did you perform?: ')) else: break

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!