Which line of code should you use?
What should you use to develop the solution?
You are building a multiplayer online game that will be deployed to an application server named Server1.
Clients will have a low-latency, persistent connection to Server1.
You need to identify a solution for the game. The solution must meet the following requirements:
Allows clients to accept low-latency push events from Server1
Allows clients to receive onmessage events from Server1
What should you use to develop the solution?
Which code snippet should you include in the function?
How should you compete the code?
DRAG DROP
You develop the following code:
You need to complete the code to meet the following requirements:
Display “aNumber is big” if aNumber is more than 10.
Display “aNumber is not big” if aNumber is equal to or less than 10.
How should you compete the code? To answer, drag the appropriate code elements to the correct targets in the
answer area. Each code element 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:
How should you complete the markup?
DRAG DROP
You are developing a web application.
You need to create an input field to provide users with the ability to select a product from a drop-down list. The
solution must meet the following requirements:
The drop-down list must use AutoComplete.
Users must see Car and Boat as the two available options.
Users must be able to select one of the two options or to enter manually their own option in the text box.
You write the following HTML markup.
How should you complete the markup? To answer, drag the appropriate code elements to the correct targets.
Each code element 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:
Which code segment should you use?
You are developing a website that helps users locate restaurants in their area from a browser. You created a
function named findRestaurants().
The function must:
Get the current latitude and longitude of the user’s device
Pass the user’s location to findRestaurants()
You must ensure that the application accesses the geolocation information from the device before searching for
restaurants.
Which code segment should you use?
Which code segment should you use?
You are developing an application that consumes an external web service. The web service returns the latest
stock rate. The application has two methods:
The getResults() method makes an AJAX web service request.
The ShowRate() method displays the stock rate from the web service response.The application has two JavaScript variables named newStockRate and stockRate to store the latest and
previous stock rates, respectively.
Users must be able to compare the old stock rate with the new stock rate.
You need to ensure that newStockRate and stockRate retain their values for comparison.
Which code segment should you use?
Which line of code should you use?
Which line of code should you use?
An HTML page contains no embedded JavaScript or CSS code. The body of the page contains only the
following line of code.
<p id=”test”>test</p>A CSS style sheet must be applied dynamically. The style must visibly change the appearance of the paragraph
on the page.
You need to apply a style to the paragraph.
Which line of code should you use?
Which CSS selector should you use?
You develop an HTML application that contains a table that displays a list of products. The table is defined with
the following HTML markup:
You must style the table to look like the following image:
You need to implement the CSS selectors to select the rows that must have a blue background.
Which CSS selector should you use?