Computers and Technology

Given a variable modelYear and a String modelName, write a statement that assigns true to recalled if the values of modelYear and modelName match the recall details and assigns false otherwise. I have

if((modelYear>=1999 && modelYear<=2002 && modelName=="Extravagant") || (modelYear>=2004 && modelYear<=2007 && modelName=="Guzzler")){
recalled=true;}
else recalled = false;

This might be too much if they already state these variables as boolean values. Is this correct according to the directions?

answer
Answers: 3

Other questions on the subject: Computers and Technology

image
Computers and Technology, 22.06.2019 17:00, bnvghnbbb
Match the following. 1. show grouping of word processing tasks that can be performed quick access toolbar 2. shortcut location for commonly used elements scroll bars 3. organized commands used to modify documents ribbon 4. used to align and measure content in a word screen zoom bar 5. vertical and horizontal bars that are used to navigate through a document contextual tabs 6. displays the name of the document in use ruler 7. allows users to enlarge or shrink a visual of a word document title bar
Answers: 2
image
Computers and Technology, 23.06.2019 06:00, sebcbal
When is a chart legend used a. all the time b. whenever you are comparing data that is the same c. whenever you are comparing multiple sets of data d. only for hand-drawn charts
Answers: 2
image
Computers and Technology, 23.06.2019 07:50, madim1275
Most shops require the technician to enter a starting and ending time on the repair order to track the actual time the vehicle was in the shop and closed out by the office. this time is referred to as _ time ? a. comeback b. ro c. cycle d. lead
Answers: 1
image
Computers and Technology, 23.06.2019 19:50, Aprillove7939
Which feature is selected to practice and save the timing of a presentation
Answers: 1
Do you know the correct answer?
Given a variable modelYear and a String modelName, write a statement that assigns true to recalled i...

Questions in other subjects:

Konu
Mathematics, 28.02.2020 22:25