MATLAB essential/Quiz 3: Control flow

This will be a quiz on control flow. Question 1. (if statements) write matlab code based on the figure 1