"choose two" , its D & E
HOTSPOT
You are writing a JavaScript program for Blue Yonder Airlines. The program stores various information about the airlines
flights.
The program has initialized the following variables:
You need to determine the data type of the code segment based on initialization and the assignment of the variables. Use
the drop-down menus to select the answer choice that answers each question based on the information presented in the
code segment.
NOTE: Each correct selection is worth one point.
Hot Area:
Explanation:
References: https://www.w3schools.com/js/js_datatypes.asp
HOTSPOT
You are planning to use the Math object in a JavaScript application. You write the following code to evaluate various Math
functions:
What are the final values for the three variables? To answer, select the appropriate values in the answer area.
NOTE: Each correct selection is worth one point.
Hot Area:
Explanation:
References: https://www.w3schools.com/js/js_math.asp
HOTSPOT
You are using JavaScript to create a function that calculates admission price.
The function must meet the following requirements:
The function accepts the age of the customer as a parameter
A customer who is less than 5 years old gets in free
A customer who is 65 years old or older gets in free
A customer who is 5 years old to 17 years old, pays $10 USD All other customers pay $20 USD
How should you complete the code? To answer, select the appropriate code segments in the answer area.
NOTE: Each correct selection is worth one point.
Hot Area:
Explanation:
References: https://www.w3schools.com/jsref/jsref_operators.asp
You are writing a function that calculates the remainder for integer division. The function receives two parameters, a and b,
and must return the remainder that is left over when the integer a is divided by the integer b.
You create the following code. Line numbers are for reference only.
You want to complete the function for lines 02 and 03.
Which two sets of code segments should you use? Each correct answer presents a complete solution. (Choose two.)
E
Explanation:
References: https://www.w3schools.com/js/js_arithmetic.asp
"choose two" , its D & E
You are writing a JavaScript program for Contoso Suites that will output HTML.
You need to output each room type on a new line using the correct method.
You create the following code for the function. Line numbers are included for reference only.
You need to insert the correct code at Line 9. Which line should you use?
B
None
HOTSPOT
You work as a JavaScript developer for Adventure Works. You are writing a simple script that performs the following actions:
Declares and initializes an array
Fills the array with 10 random integers
Adds every other number starting with the first element
How should you complete the code? To answer, select the appropriate code segments in the answer area.
NOTE: Each correct selection is worth one point.
Hot Area:
Explanation:
References: https://www.w3schools.com/jsref/jsref_push.asp https://www.w3schools.com/js/js_arrays.asp
https://stackoverflow.com/questions/9813573/how-to-perform-a-sum-of-an-int-array
HOTSPOT
For each of the following segments, select Yes if the statement is true. Otherwise, select No.
NOTE: Each correct selection is worth one point.
Hot Area:
Explanation:
References: https://www.w3schools.com/tags/ref_httpmethods.asp
DRAG DROP
You are creating a web page that requests a username.
You create the following HTML form:
You need to write a function that retrieves the username from the form.
How should you complete the code? To answer, drag the appropriate code segments to the correct locations. Each function
may be used once, more than once, or not at all. You may need to drag the split bar between panes or scroll to view content.
NOTE: Each correct selection is worth one point.
Select and Place:
Explanation:
References: https://www.w3schools.com/jsref/coll_doc_forms.asp
DRAG DROP
You are creating a web page with a script. The script will insert the windows location inside the pages input element.
How should you complete the code? To answer, drag the appropriate code segment to the correct locations. Each code
segment may be used once, more than once, or not at all. You may need to drag the split bar between panes or scroll to
view content.
Select and Place:
Explanation:
References: https://www.w3schools.com/js/js_window_location.asp
DRAG DROP
You need to write a loop that will traverse the length of an array to find the value orange. If an array element value is null, the
code should immediately go to the next element. When the value is found, the loop should exit.
How should you complete the code? To answer, drag appropriate keywords to the correct locations. Each keyword may be
used once, more than once, or not at all. You may need to drag the split bar between panes or scroll to view content.
Select and Place:
Explanation:
References:
https://www.w3schools.com/js/js_arrays.asp https://www.w3schools.com/js/js_break.asp
HOTSPOT
You evaluate the following code:
You need to determine the values of sampleStudent, sampleCourse.name, and sampleCourse.grade that are output by
console.log().
What are the final values for the three variables? To answer, select the appropriate values in the answer area.
Hot Area:
Explanation:
References: https://www.w3schools.com/js/js_output.asp
HOTSPOT
You are creating a calendar application. You need to ensure that the code works correctly for all months of the year.
How should you complete the code? To answer, select the appropriate options in the answer area.
NOTE: Each correct selection is worth one point.
Hot Area:
Explanation:
References: https://www.w3schools.com/js/js_break.asp https://www.w3schools.com/jsref/jsref_switch.asp
HOTSPOT
You are creating a function that does safe division.
The function has the following requirements:
The function receives two parameters for the numerator and denominator.
If the denominator is zero, the function must return false.
If the denominator is not zero, the function must return true.
You write the following code. Line numbers are included for reference only.
For each of the following statements, select Yes if the statement is true. Otherwise, select No.
NOTE: Each correct selection is worth one point.
Hot Area:
Explanation:
References: https://www.w3schools.com/js/js_comparisons.asp https://www.w3schools.com/jsref/jsref_if.asp
DRAG DROP
Evaluate the following code. Line numbers are included for reference only.
What is the value of each variable at line 07? To answer, drag the appropriate value to the correct variable. Each value may
be used once, more than once, or not at all. You may need to drag the split bar between panes or scroll to view content.
NOTE: Each correct selection is worth one point.
Select and Place:
Explanation:
References: https://www.w3schools.com/js/js_arithmetic.asp
DRAG DROP
You are developing a web page that uses JavaScript. The script needs to display information to the user using a popup box.
Match each function that displays a popup box with its appropriate scenario.
To answer, drag the appropriate function from the column on the left to its appropriate scenario on the right. Each function
may be used once, more than once, or not at all.
NOTE: Each correct selection is worth one point.
Select and Place:
Explanation:
References: https://www.w3schools.com/js/js_popup.asp
line 05 is a string.