Question: use matlab or octave to code. Do not use if statements, while or for loops, input statements, fprintf, or disp. use only vectors and functions

use matlab or octave to code. Do not use if statements, while or for loops, input statements, fprintf, or disp. use only vectors and functions
2. (Colon Operator 1) This question tests your ability to use the colon operator to extract subvector from a given vector. sub_vec Function: Input parameters: an original vector from which we would like to extract a subvector a scalar representing the starting index for the subvector a scalar representing the increment between indices for the subvector Output parameters: a vector whose elements are extracted from the input vector according to the other inputs Possible sample cases are: >> [out_vec] out vec = 3 subvec ([1 3 2 -3 5 9 4 12 2 -1), 2, 4) 9 -1
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
