Multiple Choice
Case-Based Critical Thinking Questions Case 9-2 Gregor, a software developer, is developing a calendar application. He has to use several if conditional statements to ensure that the calendar displays the exact number of days present in each month of each year. He creates a dayCount array to keep track of the number of days in each month. Gregor wants to create a condition to ensure that all the years divisible by 4 should contain 29 days in February. Which of the following statements should he use?
A) if (thisYear % 4 === 0) { dayCount[1] = 29; }
B) if (this year/4 === 0) { dayCount[2] = 29; }
C) if (this year*4==0) { dayCount[1] = 29 }
D) if (thisYear % 4 dayCount[2] = 29; }
Correct Answer:

Verified
Correct Answer:
Verified
Q22: The value of the length property can
Q29: Identify the general syntax of the do/while
Q31: Identify the general syntax of the forEach
Q35: What is the output of the following
Q36: Case-Based Critical Thinking Questions Case 9-1 Melissa,
Q37: Case-Based Critical Thinking Questions Case 9-2 Gregor,
Q51: When a <u>pass </u>statement is encountered,control is
Q58: <u>Statement labels</u> are used to identify statements
Q71: Identify the expression in which the initial
Q83: When each entry in an array matches