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?
A. DEBUG = http, https node server.js
B. NODE_DEBUG =http, https node server.js
C. DEBUG =true node server.js
D. NODE_DEBUG =true node server.js
A developer creates a generic function to log custommessages 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?
A. Assert
B. Log
C. Message
D. Info
E. Error
Considering the implications of 'use strict' on line 04, which three statements describe the execution of the code? Choose 3 answers
A. z is equal to 3.14.
B. 'use strict' is hoisted, so it has an effect on all lines.
C. 'use strict' has an effect only on line 05.
D. 'use strict' has an effectbetween line 04 and the end of the file.
E. Line 05 throws an error.
Refer to the code below:
Which value can a developer expect when referencing country,capital,cityString?
A. 'London'
B. undefined
C. An error
D. 'NaN'
Which two code snippetsshow working examples of a recursive function?
Choose 2 answers
A. Let countingDown = function(startNumber) { If ( startNumber >0) { console.log(startNumber) ; return countingDown(startNUmber); } else { return startNumber; }};
B. Function factorial ( numVar ) { If (numVar < 0) return; If ( numVar === 0 ) return 1; return numVar -1;
C. Const sumToTen = numVar => { If (numVar < 0) Return; return sumToTen(numVar + 1)};
D. Const factorial =numVar => { If (numVar < 0) return; If ( numVar === 0 ) return 1; returnnumVar * factorial ( numVar - 1 ); };
Given the code below: What is logged to the console'
A. 1 2 3 4 5
B. 1 2 5 3 4
C. 2 5 1 3 4
D. 2 5 3 4 1
Refer to the code below: Which replacement for the conditionalstatement on line 02 allows a developer to correctly determine that a specific element, myElement on the page had been clicked?
A. event.target.id =='myElement'
B. PlaceHolder
C. PlaceHolder
D. PlaceHolder
A developer initiates a server with the file server,js and adds dependencies in the source codes package,json that are required to run the server. Which command should the developer run to start the server locally?
A. start server,js
B. npm start server,js
C. npm start
D. node start
Given the JavaScript below:
Which code should replace the placeholder comment on line 06 to hide accounts that do not match the search string?
A. `None' : `block'
B. `Visible : 'hidden'
C. `Hidden, visible
D. `Block' : `none'
Given the following code:
What is the output of line 02?
A. "null"
B. "x-
C. "undefined" 0
D. 'object"