CRT-600 Exam Question 36

Given the JavaScript below:
01 function filterDOM (searchString) {
02 const parsedSearchString = searchString && searchString.toLowerCase() ;
03 document.quesrySelectorAll(' .account' ) . forEach(account => (
04 const accountName = account.innerHTML.toLOwerCase();
05 account. Style.display = accountName.includes(parsedSearchString) ? /*Insert code*/;
06 )};
07 }
Which code should replace the placeholder comment on line 05 to hide accounts that do not match the search string?
  • CRT-600 Exam Question 37

    developer has a web server running with Node.js. The command to start the web server is node server,js. The web server started having latency issues. Instead of a one second turn around for web requests, the developer now sees a five second turnaround, Which command can the web developer run to see what the module is doing during the latency period?
  • CRT-600 Exam Question 38

    Which option is true about the strict mode in imported modules?
  • CRT-600 Exam Question 39

    Refer to the code below:
    let o = {
    get js() {
    let city1 = String("st. Louis");
    let city2 = String(" New York");
    return {
    firstCity: city1.toLowerCase(),
    secondCity: city2.toLowerCase(),
    }
    }
    }
    What value can a developer expect when referencing o.js.secondCity?
  • CRT-600 Exam Question 40

    Refer to the code below:
    function foo () {
    const a =2;
    function bat() {
    console.log(a);
    }
    return bar;
    }
    Why does the function bar have access to variable a ?