Completed Exercise 2; instead of switch statement created if and elseif statement