JavaScript-Developer-I Exam Question 76

A developer writers the code below to calculate the factorial of a given number.
Function factorial(number) {
Return number + factorial(number -1);
}
factorial(3);
What is the result of executing line 04?
  • JavaScript-Developer-I Exam Question 77

    Given the JavaScript below:

    Which code should replace the placeholder comment on line 05 to highlight accounts that match the search string'
  • JavaScript-Developer-I Exam Question 78

    Given the following code:

    Which replacement for the conditional statement on line 02 allows a developer to correctly determine that a button on the page is clicked?
  • JavaScript-Developer-I Exam Question 79

    A developer is required to write a function that calculates the sum of elements in an array but is getting undefined every time the code is executed. The developer needs to find what is missing in the code below.
    Const sumFunction = arr => {
    Return arr.reduce((result, current) => {
    //
    Result += current;
    //
    ), 10);
    );
    Which option makes the code work as expected?
  • JavaScript-Developer-I Exam Question 80

    A developer wants to leverage a module to print a price in pretty format, and has imported a method as shown below:
    Import printPrice from '/path/PrincePrettyPrint. Js';
    Based on the code, what must be true about the printPrice function of the PricePrettyPrint modules for this import to work?