Coding the if and else statements