Question: U***using octave 3. Use the while-loop statement to generate a random number between-9 and 1 repeatedly until a positive number is generated, and if so,
U***using octave
3. Use the while-loop statement to generate a random number between-9 and 1 repeatedly until a positive number is generated, and if so, to create an array that has all generated random numbers as elements. As you expected, only the very last element of the array should be positive but all the other elements should be negative or zero
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
