Question 71

Refer to the HTML below:

Which JavaScript statement results in changing ''Tony'' to ''Mr. T. ''?
  • Question 72

    A developer creates a generic function to log custom messages in the console. To do this, the function below is implemented.
    01 function logStatus(status){
    02 console./*Answer goes here*/{'Item status is: %s', status};
    03 }
    Which three console logging methods allow the use of string substitution in line 02?
  • Question 73

    Refer to the following code:
    < html lang= " en " >
    < body >
    < button class= " secondary " > Save draft < /button >
    < button class= " primary " > Save and close < /button >
    < /body >
    < script >
    function displaySaveMessage(event) {
    console.log( ' Save message. ' );
    }
    function displaySuccessMessage(event) {
    console.log( ' Success message. ' );
    }
    window.onload = function() {
    document.querySelector( ' .secondary ' )
    .addEventListener( ' click ' , displaySaveMessage, true);
    document.querySelector( ' .primary ' )
    .addEventListener( ' click ' , displaySuccessMessage, true);
    }
    < /script >
    < /html >
  • Question 74

    Refer to the following array:
    Let arr = [1, 2, 3, 4, 5];
    Which three options result in x evaluating as (3, 4, 5)?
    Choose 3 answers
  • Question 75

    developer publishes a new version of a package with new features that do not break
    backward compatibility. The previous version number was 1.1.3.
    Following semantic versioning format, what should the new package version number
    be?