1) What is Node.js? a) A. A front-end framework b) A runtime environment for executing JavaScript code outside the browser c) A database management system d) A CSS preprocessor 2) Which module is used in Node.js to handle HTTP requests and responses? a) http b) url c) fs d) events 3) How do you install a Node.js module? a) node install <module_name> b) npm install <module_name> c) npm add <module_name> d) module install <module_name> 4) What command is used to initialize a new Node.js project? a) npm init b) node start c) npm start d) node init 5) What type of database is MongoDB? a) Relational b) NoSQL c) File-based d) Key-Value Store 6) Which package is commonly used to define models in Node.js for MongoDB? a) Sequelize b) Mongoose c) Express d) Lodash 7) What does the Schema in Mongoose define? a) The database connection string b) The structure and constraints of documents in a collection c) The default port for the database d) The middleware to use in an application 8) What method is used to define a GET route in Express.js? a) app.get() b) app.route() c) app.fetch() d) app.create() 9) What does res.send() do in Express.js? a) Ends the request and sends data back to the client b) Starts a new server c) Parses the request body d) Redirects the client to another route 10) What is the purpose of mongoose.connect()? a) To define a schema b) To start the Node.js server c) To establish a connection to the MongoDB database d) To create a new model
0%
Final assessment - Nodejs
แชร์
แชร์
แชร์
โดย
Kdyahya
แก้ไขเนื้อหา
สั่งพิมพ์
ฝัง
เพิ่มเติม
กำหนด
ลีดเดอร์บอร์ด
แสดงเพิ่มขึ้น
แสดงน้อยลง
ลีดเดอร์บอร์ดนี้ตอนนี้เป็นส่วนตัว คลิก
แชร์
เพื่อทำให้เป็นสาธารณะ
ลีดเดอร์บอร์ดนี้ถูกปิดใช้งานโดยเจ้าของทรัพยากร
ลีดเดอร์บอร์ดนี้ถูกปิดใช้งานเนื่องจากตัวเลือกของคุณแตกต่างสำหรับเจ้าของทรัพยากร
แปลงกลับตัวเลือก
แบบทดสอบ
เป็นแม่แบบแบบเปิดที่ไม่ได้สร้างคะแนนสำหรับลีดเดอร์บอร์ด
ต้องลงชื่อเข้าใช้
สไตล์ภาพ
แบบ อักษร
ต้องสมัครสมาชิก
ตัวเลือก
สลับแม่แบบ
แสดงทั้งหมด
รูปแบบเพิ่มเติมจะปรากฏเมื่อคุณเล่นกิจกรรม
เปิดผลลัพธ์
คัดลอกลิงค์
คิวอาร์โค้ด
ลบ
คืนค่าการบันทึกอัตโนมัติ:
ใช่ไหม