Question: matlab Consider the code given below. n = 8; i = 0; whilen > 0 if mod in, 3)==0 i = i + 1; outArr(i)
Consider the code given below. n = 8; i = 0; whilen > 0 if mod in, 3)==0 i = i + 1; outArr(i) = n; end n = n - 1; end Matlab command mod(a,m): be mod(a,m) returns the remainder after division of a bym, where a is the dividend and m is the divisor An example: bs mod(23,5) will result in b-3 What elements will be assigned to array outArr? Please explain every repetition of the while loop
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
