The following vector is defined in MATLAB: v = [6 11 -4 5 8 1 -0.2 -7

Question:

The following vector is defined in MATLAB:
v = [6 11 -4 5 8 1 -0.2 -7 19 5]
By hand (pencil and paper) write what will be displayed if the following commands are executed by MATLAB. Check your answers by executing the commands with MATLAB.
(a) a = [v[(1:3 7:-1 1:5]) ;v[(10,1,4:6,2])]
(b) b = [v([9, 2:4, 1])' v ([5 3 10 2 7])' v ([10: –2:4, 10])']
Fantastic news! We've Found the answer you've been seeking!

Step by Step Answer:

Related Book For  book-img-for-question
Question Posted: