Question: The purpose of this program is to identify data on a randomly generated set of numbers, which is deemed incorrect, for testing procedures. Any number
The purpose of this program is to identify data on a randomly generated set of numbers, which is deemed incorrect, for testing procedures. Any number greater than 90 is considered invalid data. If a number on the data set is found matching this criteria, then this value must be replaced with a 0. The user will have the choice to continue to generate random numbers to test, or to quit the program.
Create a function called randNum that accepts two integers M and N as input and returns a randomly generated MxN array A of floating point numbers in the interval (50-100). Write a script to ask a user to enter the dimensions of an array, M and N. The code should go through all elements on the array and check if there is a value or values greater than 90. If the values are found, those values should be replaced with a 0. After all numbers are evaluated, the array should be displayed. The user will also have to choose if to try again with a new set of numbers, or to quit. If the user inputs character "e", the program must exit. No other input will terminate the program. If the program enters the choise "c", the program will execute again. You MUST use a loop to manipulate the matrix. ____MATLAB
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
