Question: Write a MATLAB function named listLook The function will have two inputs and one return value. The first input will be a list of values.

Write a MATLAB function named listLook

  • The function will have two inputs and one return value.
  • The first input will be a list of values.
  • The second input will be a postive integer, n, no greater than the length of the list.
  • The return value should be nth value in the list.

Notes:

  • Example Test Case: list = [20 40 60 80 100 20]; [nth] = listLook(list,2); results in nth=40
  • DO NOT include test cases.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!