Question: Q 1 . Basic Operations with Lists and Arrays You are given the failure times ( in hours ) of five machines as a list:
Q Basic Operations with Lists and Arrays
You are given the failure times in hours of five machines as a list: failuretimes Write a Python script to:
Find the total operational time sum of failure times
Find the average failure time.
Q Simple Function for Reliability Classification
Write a Python function isreliable that takes a failure time as input and returns 'Reliable' if the failure time is above hours, and 'Unreliable' otherwise. Test this function with a failure time of hours.
Q Numpy Basics: Mean and Sum
Using Numpy, create an array of failure times: failuretimes nparray Find:
The total failure time.
The mean failure time.
Q Counting Failures Above a Threshold
You have a list of machine failure times: failuretimes Write a Python script to count how many times a machine failed after running for more than hours.
Q Creating and Accessing a Dictionary
Create a dictionary called machinedata where each key is a machine ID and the value is its failure time. Then, retrieve and print the failure time of machine with ID 'Machine
Q Creating Simple Plots
You have failure times for four machines: failuretimes Plot a simple bar chart using Matplotlib, where the xaxis represents machine IDs Machine Machine etc. and the yaxis represents failure times.
Q Finding Maximum and Minimum Values
You are given an array of failure times: failuretimes nparray Using Numpy, find:
The maximum failure time.
The minimum failure time.
Q Filtering Data
Using a list of failure times: failuretimes Write a Python script to filter out the failure times that are less than hours and print the remaining times.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
