Question: 2. (2pts) Write a MATLAB function which returns every other element of the vector passed in. That is, it returns the all odd- numbered elements,
2. (2pts) Write a MATLAB function which returns every other element of the vector passed in. That is, it returns the all odd- numbered elements, starting with the first. Example: input x = [7 2 10 3 5 1 6] Output should be [7 10 5 6]
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
