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
Q42: Identify a true statement of array.some(callback [,thisArg])method.
A)
Q43: The _ method diminishes array from the
Q54: Identify a method that decreases array by
Q58: Identify the general structure for accessing each
Q61: Identify the letter of the choice that
Q63: Identify the letter of the choice that
Q64: Case-Based Critical Thinking Questions Case 9-1 Melissa,
Q65: Identify the letter of the choice that
Q68: The _ statement stops processing the commands
Q82: Describe the structure of the if else
Unlock this Answer For Free Now!
View this answer and more for free by performing one of the following actions
Scan the QR code to install the App and get 2 free unlocks
Unlock quizzes for free by uploading documents