Question: 1. Write a Matlab program using WHILE loop that computes the sum of the elements of an array. Load the lab7.mat file and from it,

1. Write a Matlab program using WHILE loop that computes the sum of the elements of an array. Load the lab7.mat file and from it, use Array1 as the sample array to compute the sum. Use the length command to know the elements in the array.

Write a Matlab program using WHILE loop that computes the largest element of an array. Load lab7.mat, and use Array1 as the sample array to test your program. Use the length command to know the elements in the array.

Use a while loop to write a program that given a vector of numbers computes how many numbers are greater than 10. Use Array2 to check your program.Write a program that reads numbers from the user and computes their sum until the user enters a negative number. Test program to illustrate functionality.

Array1 =

71 3 28 5 10 82 69 32 95 3 44 38 77 80 19

Array2 =

7 5 10 3 11 4 1 12 15 2

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!