Clunker Motors Inc is recalling all vehicles in its Extravagant line from model years 1999 – 2002. Given an int variable modelYear and a string modelName write a statement that prints the message “RECALL” to standard output if the values of modelYear and modelName match the recall details.

LANGUAGE: Visual Basic

CHALLENGE:

Clunker Motors Inc is recalling all vehicles in its Extravagant line from model years 1999 – 2002. Given an int variable modelYear and a string modelName write a statement that prints the message “RECALL” to standard output if the values of modelYear and modelName match the recall details.

SOLUTION:

If modelYear >= 1999 And modelYear <= 2002 And modelName = "Extravagant" Then
    MessageBox.Show("RECALL")
End If