Basic solution using nested if statements