Online Exam Quiz

questionQuestion  1 to 30

How do you handle errors in Express.js?

  • Using error-handling middleware
  • Using error functions
  • Using try-catch blocks
  • Using error routes
Mark for review

What is the default port for a MongoDB server?

  • 27017
  • 28017
  • 3000
  • 8080
Mark for review

How do you install a package in Node.js using npm?

  • npm start
  • npm install [package_name]
  • npm add [package_name]
  • npm get [package_name]
Mark for review

Which command is used to create a new component in Angular?

  • ng generate component [name]
  • ng create component [name]
  • ng new component [name]
  • ng add component [name]
Mark for review

How do you update Node.js to the latest version?

  • node update
  • node upgrade
  • npm install -g node
  • npm install -g n && n latest
Mark for review

Which command is used to install Express.js in a Node.js project?

  • npm install express
  • npm get express
  • npm add express
  • npm new express
Mark for review

Node.js is built on which JavaScript engine?

  • V8 Engine
  • SpiderMonkey
  • JavaScriptCore
  • ChakraCore
Mark for review

Which command is used to create a new Angular project?

  • ng init
  • ng create
  • ng new
  • ng generate
Mark for review

Which framework is used for developing the front-end in MEAN stack?

  • React
  • Vue.js
  • Angular
  • Svelte
Mark for review

In Angular, which decorator is used to define a component?

  • @Component
  • @Directive
  • @Injectable
  • @Service
Mark for review

In MongoDB, what is an index?

  • A record
  • A query
  • A data structure
  • A collection
Mark for review

In Express.js, which method is used to define a POST route?

  • app.post()
  • app.routePost()
  • app.postRoute()
  • app.route()
Mark for review

Which of the following is used to run a MongoDB server locally?

  • mongo
  • mongod
  • mongodb
  • mongo run
Mark for review

Which CLI tool is used to create and manage Angular applications?

  • AngularJS CLI
  • Angular CLI
  • ng CLI
  • Angular App CLI
Mark for review

How do you define a model in Mongoose?

  • mongoose.Schema()
  • mongoose.Model()
  • mongoose.createModel()
  • mongoose.define()
Mark for review

Which method is used to create a new document in a MongoDB collection?

  • insert
  • insertDocument
  • insertOne
  • insertDoc
Mark for review

In Angular, how do you bind data from the component to the template?

  • Data Binding
  • Property Binding
  • Event Binding
  • Two-way Binding
Mark for review

What is the command to install Mongoose in a Node.js project?

  • npm install mongoose
  • npm get mongoose
  • npm add mongoose
  • npm new mongoose
Mark for review

In Angular, which file is responsible for configuring the routes?

  • app-routing.module.ts
  • routes.module.ts
  • app.routes.ts
  • router.config.ts
Mark for review

What is the primary purpose of MongoDB in the MEAN stack?

  • Hosting Static Files
  • Front-end Rendering
  • Backend Framework
  • Database
Mark for review

Which directive is used for conditional rendering in Angular?

  • *ngIf
  • *ngFor
  • *ngBind
  • *ngModel
Mark for review

What does MEAN stack stand for?

  • MongoDB, Express, Angular, Node
  • MySQL, Express, Angular, Node
  • MongoDB, Express, AngularJS, Node
  • MongoDB, ExpressJS, AngularJS, Node
Mark for review

In Express.js, which method is used to define a GET route?

  • app.get()
  • app.routeGet()
  • app.getRoute()
  • app.route()
Mark for review

In MongoDB, what is a document?

  • A collection of databases
  • A record in a collection
  • A type of index
  • A field in a record
Mark for review

In Angular, which lifecycle hook is called once after the first ngOnChanges()?

  • ngOnInit
  • ngDoCheck
  • ngAfterContentInit
  • ngAfterViewInit
Mark for review

How do you start an Express.js server?

  • express start
  • node server.js
  • node app.js
  • start server
Mark for review

Which database is used in the MEAN stack?

  • MySQL
  • MongoDB
  • SQLite
  • PostgreSQL
Mark for review

In MEAN stack, what does Express.js provide?

  • Database Management
  • Server-side logic
  • Front-end Framework
  • Version Control
Mark for review

What is the default port for an Express.js application?

  • 3000
  • 8080
  • 5000
  • 4000
Mark for review

What is the use of the Angular service?

  • To handle HTTP requests
  • To handle routing
  • To manage state
  • To create reusable code
Mark for review

blinkerOnline

  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26
  • 27
  • 28
  • 29
  • 30
  • Answered
  • Not Answered
  • Marked for Review