subject
Engineering, 29.03.2021 06:00 FavvBella84

You do not need to use or create any user-defined functions in this program You need to import random, time, math libraries
You need to use time, sleep 0, candom. randrange (), math. sgrt () and
rath. pou () functions (see examples from handout from week 4 and 5)
Prompt the user for a number (float)
Use that number to output for things using built-in Python functions:
Sleep (pause) for that many seconds
Output a random number between 1 and the number entered by the user
o Output the square root of the number entered by the user
o Output the result of the number entered by the user to the power of 2
Your output should look like the same run below (but should allow for user input of the number)
Sample Run (based on user input of 4)
Please enter a number: 4
Sleeping for 4.0 seconds
Random number is: 2
The square root of 4,0 =2.0
4.0 to the power of 2 = 16.0

ansver
Answers: 1

Another question on Engineering

question
Engineering, 04.07.2019 18:10
At 12 noon, the count in a bacteria culture was 400; at 4: 00 pm the count was 1200 let p(t) denote the bacteria cou population growth law. find: (a) an expression for the bacteria count at any time t (b) the bacteria count at 10 am. (c) the time required for the bacteria count to reach 1800.
Answers: 1
question
Engineering, 04.07.2019 18:20
Asimple rankine cycle uses water as the working fluid. the water enters the turbine at 10 mpa and 480c while the condenser operates at 6 kpa. if the turbine has an isentropic efficiency of 80 percent while the pump has an isentropic efficiency of 70 percent determine the thermal efficiency
Answers: 1
question
Engineering, 04.07.2019 18:20
Find the minimum film thickness for a journal bearing with the data below. shaft diameter, d-50 mm, clearance ratio, cdratio? 0.001, shaft speed, n 2000 rpm; bearing length. i 200 mm; eccentricity ration, ? -0.55. ( note, cdratio-ca/d) the minimum film thickness is um
Answers: 2
question
Engineering, 04.07.2019 19:10
What is the main objective of using reheat rankine cycle?
Answers: 3
You know the right answer?
You do not need to use or create any user-defined functions in this program You need to import rand...
Questions
Questions on the website: 13722360