Question 36
The developer has a function that prints "Hello" to an input name. To test this,thedeveloper created a function that returns "World". However the following snippet does not print " Hello World".
What can the developer do to change the code to print "Hello World" ?
Question 37
Refer to the code below:
01 let sayHello = () => {
02 console.log('Hello, World!');
03 };
Which code executes sayHello once, two minutes from now?
Question 38
A developer wants to use a try...catch statement to catch any error that countSheep () may throw and pass it to a handleError () function.
What is the correct implementation of the try...catch?
Question 39
A developer has a fizzbuzz function that, when passed in a number, returns the following:
- 'fizz' if the number is divisible by 3.
- 'buzz' if the number is divisible by 5.
- 'fizzbuzz' if the number is divisible by both 3 and 5.
- empty string if the number is divisible by neither 3 or 5.
Which two test cases properly test scenarios for the fizzbuzz function?
Choose 2 answers
Question 40
Given the HTML below:
Which statement adds the priority-account CSS class to the Universal Containers row?
