๐Ÿงช Node JS MCQ Quiz Hub

Nodejs Mcq Question Set 2

Choose a topic to test your knowledge and improve your Node JS skills

What are the key features of Node.js?





โœ… Correct Answer: 4

How can we check the current version of NPM?





โœ… Correct Answer: 1

What is the advantage of using node.js?





โœ… Correct Answer: 4

Why a Node.JS code is pretty fast although being written in JavaScript?





โœ… Correct Answer: 3

What is REPL in Node.js?





โœ… Correct Answer: 4

Which module is used to serve static resources in Node.js?





โœ… Correct Answer: 1

What should you do in your code to improve your application's performance?





โœ… Correct Answer: 1

Is console a global object?





โœ… Correct Answer: 1

To install Node.js express module





โœ… Correct Answer: 1

Which of the followings are valid languages for Node.js?





โœ… Correct Answer: 1

Which of the following tool automates various tasks of Node.js application?





โœ… Correct Answer: 2

In Node.js APIs of Node.JS are which of the following?





โœ… Correct Answer: 1

Which of the following class is used to create and consume custom events in Node.js?





โœ… Correct Answer: 1

Node.js supports which of the following platform?





โœ… Correct Answer: 4

Which of following are a valid form of route path?





โœ… Correct Answer: 4

Which of the following statements holds good with respect to Node?





โœ… Correct Answer: 1

In Nodejs what is use of underscore variable in REPL session?





โœ… Correct Answer: 4

Which statement is valid in using a Node module fs in a Node based application?





โœ… Correct Answer: 1

Child processes always have three streams child.stdin, child.stdout, and child.stderr which may be shared with the stdio streams of the parent process.





โœ… Correct Answer: 1

Which of the following is true about Node.js?





โœ… Correct Answer: 4

Which of the following is false?





โœ… Correct Answer: 2

Node.js files must be initiated in the?





โœ… Correct Answer: 1

Syntax to Initiate the Node.js File is?





โœ… Correct Answer: 3

Which keyword is used to make properties and methods available outside the module file?





โœ… Correct Answer: 3

Which method appends specified content to a file.





โœ… Correct Answer: 1

Which of the following command will show version of Node?





โœ… Correct Answer: 4

which of the following areas, Node.js is not advised to be used?





โœ… Correct Answer: 3

The URL module splits up a web address into readable parts.





โœ… Correct Answer: 1

Node.js uses _______ programming.





โœ… Correct Answer: 1

Node.js files have extension?





โœ… Correct Answer: 3

Node.js runs?





โœ… Correct Answer: 4

To include a module, use the _______ function with the name of the module.





โœ… Correct Answer: 2

Node.js has a built-in module called?





โœ… Correct Answer: 2

Which method to create an HTTP server?





โœ… Correct Answer: 1

Which of the following is true about process global object?





โœ… Correct Answer: 4

A package in Node.js contains all the files you need for a module.





โœ… Correct Answer: 1

The fs.read() method is used to read files on your computer.





โœ… Correct Answer: 2

Which statement execute the code of sample.js file?





โœ… Correct Answer: 2

How can we create instance of http module ?





โœ… Correct Answer: 1

The $ npm ls -g statement is used to list down all the locally installed module?





โœ… Correct Answer: 2

How can we check the cujrrent version of NPM?





โœ… Correct Answer: 1

The $ npm ls statement is used to list down all the locally installed module?





โœ… Correct Answer: 1

package.json is is used to define the properties of a package?





โœ… Correct Answer: 1

What would be the output of the below code ? var http = require("http"); http.createServer(function (request, response) { response.writeHead(200, {'Content-Type': 'text/plain'}); response.end('Welcome to the nodejs '); }).listen(8083); console.log('Server running at http://127.0.0.1:8083/');





โœ… Correct Answer: 1

What would be the output of the below code ? $ node > var y = 10





โœ… Correct Answer: 3

Find output of the following program ? $ node > 15 + ( 2 * 4 ) - 8





โœ… Correct Answer: 1

Guess the output of the following program ? $ node > var k=10 undefined > y=10 10 > k+y





โœ… Correct Answer: 3

What would be the output of the below code ? $ node > y = 10





โœ… Correct Answer: 3