Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Assignment #2 - Loops and Decisions Due: Check Blackboard Course Site for Due Date For this assignment - you will write a python program with
Assignment #2 - Loops and Decisions Due: Check Blackboard Course Site for Due Date For this assignment - you will write a python program with the following functionality: Use the following tuple values: (12, 25, 37, 51, 62, 75, 88) For each number in the above tuple, generate 20 random numbers between 1 and 100. Test these 20 random numbers against each number in the tuple and keep track of the number of times that your random number is less than or equal to your tuple number 12, 25, etc). For example, test the tuple number 12 against 20 random numbers and print the results. Next, test the tuple number 25 against a new set of 20 random numbers and print those results. Repeat this for the rest of the tuple numbers. For each tuple number, print the tuple number along with the total times your random number is less than or equal to your tuple number. Your final output should look similar to the one below (shouldn't be exact since we are dealing with random numbers): 1 2 3 25 5 37 5 51 9 62 12 75 13 88 17
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started