Clunker Motors Inc. is recalling all vehicles from model years 2001-2006. Given an int variable modelYear write a statement that prints the message “NO RECALL” to standard output if the value of modelYear DOES NOT fall within that range.

LANGUAGE: C++

CHALLENGE:

Clunker Motors Inc. is recalling all vehicles from model years 2001-2006. Given an int variable modelYear write a statement that prints the message “NO RECALL” to standard output if the value of modelYear DOES NOT fall within that range.

SOLUTION:


if(modelYear > 2000 && modelYear < 2007){}else{
    cout << "NO RECALL";
}