1. Which of the following is used to send HTTP requests from the frontend in
JavaScript?
A. XMLHttpRequest
B. SQL
C. Express
D. Node.js
Answer: a) XMLHttpRequest
Rationale: XMLHttpRequest is used in JavaScript to send HTTP requests to the
backend from the frontend.
2. Which of the following tools is used to manage state in React applications?
A. Express
B. Redux
C. Flask
D. Angular
Answer: b) Redux
,Rationale: Redux is a library used to manage the global state of React applications,
allowing for predictable state management.
3. What is the purpose of the componentDidMount lifecycle method in React?
A. To handle error boundaries
B. To initialize data after the component mounts
C. To update the state of the component
D. To render the component
Answer: b) To initialize data after the component mounts
Rationale: componentDidMount is called after a component has mounted to the DOM,
and it’s commonly used for data fetching or initialization tasks.
4. Which of the following is the default HTTP port for a web server?
A. 80
B. 443
C. 8080
D. 3000
Answer: a) 80
, Rationale: Port 80 is the default HTTP port used by web servers for standard HTTP
communication.
5. What is the purpose of the RESTful API in full-stack development?
A. To create server-side applications
B. To manage databases
C. To allow communication between frontend and backend
D. To style web pages
Answer: c) To allow communication between frontend and backend
Rationale: RESTful APIs are used for communication between the client (frontend)
and the server (backend) in a standardized way.
6. Which of the following is an essential feature of the Express.js framework?
A. Component-based architecture
B. Middleware support
C. Two-way data binding
D. Data modeling
Answer: b) Middleware support
JavaScript?
A. XMLHttpRequest
B. SQL
C. Express
D. Node.js
Answer: a) XMLHttpRequest
Rationale: XMLHttpRequest is used in JavaScript to send HTTP requests to the
backend from the frontend.
2. Which of the following tools is used to manage state in React applications?
A. Express
B. Redux
C. Flask
D. Angular
Answer: b) Redux
,Rationale: Redux is a library used to manage the global state of React applications,
allowing for predictable state management.
3. What is the purpose of the componentDidMount lifecycle method in React?
A. To handle error boundaries
B. To initialize data after the component mounts
C. To update the state of the component
D. To render the component
Answer: b) To initialize data after the component mounts
Rationale: componentDidMount is called after a component has mounted to the DOM,
and it’s commonly used for data fetching or initialization tasks.
4. Which of the following is the default HTTP port for a web server?
A. 80
B. 443
C. 8080
D. 3000
Answer: a) 80
, Rationale: Port 80 is the default HTTP port used by web servers for standard HTTP
communication.
5. What is the purpose of the RESTful API in full-stack development?
A. To create server-side applications
B. To manage databases
C. To allow communication between frontend and backend
D. To style web pages
Answer: c) To allow communication between frontend and backend
Rationale: RESTful APIs are used for communication between the client (frontend)
and the server (backend) in a standardized way.
6. Which of the following is an essential feature of the Express.js framework?
A. Component-based architecture
B. Middleware support
C. Two-way data binding
D. Data modeling
Answer: b) Middleware support