MathWorks Interview Question

Coding using Matlab