Write a python program that keeps getting random integers from a user-given range until the mean of all numbers gotten s

Business, Finance, Economics, Accounting, Operations Management, Computer Science, Electrical Engineering, Mechanical Engineering, Civil Engineering, Chemical Engineering, Algebra, Precalculus, Statistics and Probabilty, Advanced Math, Physics, Chemistry, Biology, Nursing, Psychology, Certifications, Tests, Prep, and more.
Post Reply
answerhappygod
Site Admin
Posts: 899603
Joined: Mon Aug 02, 2021 8:13 am

Write a python program that keeps getting random integers from a user-given range until the mean of all numbers gotten s

Post by answerhappygod »

Write a python program that keeps getting random integers from auser-given range until the mean of all numbers gotten so far iswithin a given epsilon of the midpoint of the range and thenreturns the count of random numbers that were necessary toget.>>> low: -100>>> high: 50>>> epsilon: 0.01405 random numbers before the mean was within 0.01 of -25.0
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!
Post Reply