Home /
Expert Answers /
Computer Science /
given-variables-to-be-used-in-your-code-below-vec-rand-1-10-num-randi-4-100-problem-1-fo-pa643
(Solved): \%Given variables to be used in your code below vec =rand(1,10) num =randi([4,100]) \%Problem 1: Fo ...
\%Given variables to be used in your code below vec =rand(1,10) num =randi([4,100]) \%Problem 1: For Loops \% Fix the following for loop so that A becomes vector 'vec' in % reverse order. If vec is [1?2?3?4?] then A should look like this % after each iteration: %[1]%[2?1?]%[3?2?1?]%[4?3?2?1?]A=0 for ind = length (A)A=[vec( ind ),vec] ind = ind +1 ; end