HomeSubjectsUniversityBlogAbout

Server-Side Programming

Topic in Web Development

210 total MCQsShowing 30 with explanations10 Easy10 Medium10 Hard

About This Topic

Server-side programming means running code on a web server to build responses dynamically, such as rendering HTML templates or processing form submissions. MCQs compare server-side rendering with client-side rendering and ask about template engines like EJS, Pug or Handlebars. You should know how the server parses request bodies, handles file uploads, sets cookies and maintains sessions, and what CGI, PHP and application servers do. Concurrency models are a recurring theme, contrasting thread-per-request servers with Node.js's event-driven, non-blocking I/O. Reverse proxies such as Nginx, WebSockets for real-time communication, and server-side request forgery (SSRF) also appear.

Below are 30 practice questions from a pool of 210 Server-Side Programming MCQs, one of 17 topics in Web Development. Each shows the correct answer with an explanation; when you are ready, take a timed quiz to test recall under exam conditions.

Practice Questions

Each question below shows the correct answer with a full explanation. Use these to build conceptual understanding before attempting a timed quiz.

Server-Side ProgrammingEasy

Q1. What is server-side rendering?

  1. A.A database operation for aggregating records
  2. B.A CSS technique for optimizing visual layout
  3. C.Rendering CSS on the server before delivery
  4. D.Generating HTML on the server before sending it✓ Correct

Explanation

SSR generates complete HTML pages on the server.

Report an error in this question

Server-Side ProgrammingEasy

Q2. Which language is commonly used for server-side programming?

  1. A.HTML
  2. B.Python✓ Correct
  3. C.CSS
  4. D.SVG

Explanation

Python is a popular server-side language used with Django and Flask.

Report an error in this question

Server-Side ProgrammingEasy

Q3. What is PHP?

  1. A.A relational database management system
  2. B.A CSS framework for responsive web layouts
  3. C.A server-side scripting language for web dev✓ Correct
  4. D.A JavaScript library for building interfaces

Explanation

PHP is a server-side scripting language designed for web development.

Report an error in this question

Server-Side ProgrammingEasy

Q4. What is Django?

  1. A.A CSS framework for responsive component design
  2. B.A NoSQL database for storing document collections
  3. C.A high-level Python web framework for rapid dev✓ Correct
  4. D.A JavaScript library for building front-end UIs

Explanation

Django is a Python web framework with built-in URL routing, ORM, and authentication.

Report an error in this question

Server-Side ProgrammingEasy

Q5. What is a template engine?

  1. A.A database tool for managing schema migrations
  2. B.A JavaScript framework for reactive UI development
  3. C.Software combining templates with data for HTML✓ Correct
  4. D.A CSS generator for building style sheets

Explanation

Template engines merge HTML templates with dynamic data to generate pages.

Report an error in this question

Server-Side ProgrammingEasy

Q6. What is the purpose of a controller in server-side MVC?

  1. A.To control the browser rendering engine
  2. B.To control CSS styles of page elements
  3. C.To handle requests, process data, and respond✓ Correct
  4. D.To control the database schema directly

Explanation

A controller receives requests, interacts with models, and selects views.

Report an error in this question

Server-Side ProgrammingEasy

Q7. What is a server-side session?

  1. A.Data stored on server to maintain user state✓ Correct
  2. B.A database backup for disaster recovery
  3. C.A CSS animation effect with keyframes
  4. D.A JavaScript variable in the global scope

Explanation

Server-side sessions store user-specific data on the server.

Report an error in this question

Server-Side ProgrammingEasy

Q8. What is Flask?

  1. A.A JavaScript runtime built on V8 engine
  2. B.A CSS container element for layouts
  3. C.A NoSQL database for document storage
  4. D.A lightweight Python web framework for apps✓ Correct

Explanation

Flask is a minimalist Python web framework.

Report an error in this question

Server-Side ProgrammingEasy

Q9. What is a request object in server-side programming?

  1. A.A database query for retrieving record sets
  2. B.A CSS class for styling specific elements
  3. C.An object containing incoming HTTP request data✓ Correct
  4. D.A JavaScript event fired by user interactions

Explanation

The request object contains information about the incoming HTTP request.

Report an error in this question

Server-Side ProgrammingEasy

Q10. What does npm start typically do?

  1. A.Starts CSS compilation for the build process
  2. B.Opens a browser window to the application URL
  3. C.Creates a new project with boilerplate code
  4. D.Runs the start script in package.json for server✓ Correct

Explanation

npm start executes the start script from package.json.

Report an error in this question

Server-Side ProgrammingMedium

Q11. What is the difference between SSR and CSR?

  1. A.They are identical in every rendering aspect
  2. B.SSR generates HTML on server; CSR generates in browser✓ Correct
  3. C.CSR is always faster in initial page load performance
  4. D.SSR is unable to use any JavaScript on the page

Explanation

SSR sends fully rendered HTML, while CSR renders content in the browser.

Report an error in this question

Server-Side ProgrammingMedium

Q12. What is a REST controller?

  1. A.A component handling HTTP requests for REST endpoints✓ Correct
  2. B.A database controller for managing query execution
  3. C.A sleep controller for pausing execution
  4. D.A CSS component for building styled page layouts

Explanation

A REST controller maps HTTP methods to handler functions for resource endpoints.

Report an error in this question

Server-Side ProgrammingMedium

Q13. What is server-side validation?

  1. A.Validating HTML syntax for standards compliance
  2. B.Validating CSS on the server for correctness
  3. C.Checking browser compatibility for CSS features
  4. D.Checking data on server to ensure requirements✓ Correct

Explanation

Server-side validation verifies data integrity on the server.

Report an error in this question

Server-Side ProgrammingMedium

Q14. What is the purpose of a .env file?

  1. A.To define HTML entities for special character display
  2. B.To style web pages with dynamic CSS variables
  3. C.To store environment-specific config like API keys✓ Correct
  4. D.To configure CSS preprocessor compilation options

Explanation

A .env file stores environment variables as key-value pairs.

Report an error in this question

Server-Side ProgrammingMedium

Q15. What is a cron job?

  1. A.A scheduled task running automatically at intervals✓ Correct
  2. B.A database backup run at a specific time point
  3. C.A JavaScript timeout for delaying code execution
  4. D.A CSS animation timer for scheduling effects

Explanation

A cron job is a time-based scheduler that runs scripts at specified intervals.

Report an error in this question

Server-Side ProgrammingMedium

Q16. What is the purpose of logging in server-side applications?

  1. A.Displaying logs visually in the browser console
  2. B.Recording events and errors for debugging and monitoring✓ Correct
  3. C.Creating log files that track CSS style changes
  4. D.Logging into user accounts through authentication

Explanation

Logging records application events, errors, and performance data.

Report an error in this question

Server-Side ProgrammingMedium

Q17. What is SSR hydration?

  1. A.A database operation for replicating table data
  2. B.A CSS technique for fluid responsive layout design
  3. C.Attaching JS event handlers to server-rendered HTML✓ Correct
  4. D.Adding water to servers for cooling systems

Explanation

Hydration is when client-side JavaScript takes over server-rendered HTML.

Report an error in this question

Server-Side ProgrammingMedium

Q18. What is a reverse proxy in server-side programming?

  1. A.A database proxy for managing connection pools
  2. B.A backwards web server that inverts requests
  3. C.A CSS preprocessor for compiling style files
  4. D.A server forwarding requests to backend servers✓ Correct

Explanation

A reverse proxy receives client requests and forwards them to backend servers.

Report an error in this question

Server-Side ProgrammingMedium

Q19. What is the purpose of body parsing middleware?

  1. A.To parse CSS files for style extraction
  2. B.To parse HTML body elements for rendering content
  3. C.To parse database queries for execution planning
  4. D.To extract and parse HTTP request bodies into objects✓ Correct

Explanation

Body parsing middleware parses incoming request bodies into JavaScript objects.

Report an error in this question

Server-Side ProgrammingMedium

Q20. What is the difference between stateless and stateful server-side apps?

  1. A.Stateless is always better for every use case scenario
  2. B.Stateless apps store no session data; stateful apps maintain it✓ Correct
  3. C.Stateful apps are completely unable to scale horizontally
  4. D.They are identical in session management behavior

Explanation

Stateless servers treat each request independently without remembering previous interactions.

Report an error in this question

Server-Side ProgrammingHard

Q21. What is the difference between process-based and event-driven server architectures?

  1. A.Process-based architectures cannot handle concurrent requests
  2. B.They are identical in concurrency approach
  3. C.Event-driven is always slower in handling concurrent requests
  4. D.Process-based creates threads per request; event-driven uses async I/O✓ Correct

Explanation

Process-based servers create threads per request, while event-driven use a single thread with non-blocking I/O.

Report an error in this question

Server-Side ProgrammingHard

Q22. What is the purpose of a load balancer?

  1. A.To balance database queries across shards
  2. B.To balance CSS style specificity weights
  3. C.To load JavaScript files in parallel
  4. D.To distribute traffic across multiple servers✓ Correct

Explanation

A load balancer distributes requests across multiple backend servers.

Report an error in this question

Server-Side ProgrammingHard

Q23. What is serverless computing?

  1. A.A client-side only architecture without any backend logic
  2. B.Computing without any servers whatsoever
  3. C.A static site generator for building HTML pages
  4. D.A cloud model with provider-managed infrastructure on demand✓ Correct

Explanation

Serverless lets developers run code without managing servers.

Report an error in this question

Server-Side ProgrammingHard

Q24. What is the difference between monolithic and microservices architecture?

  1. A.They are identical in application structure
  2. B.Monolithic is a single unit; microservices are independent✓ Correct
  3. C.Microservices are always faster in every scenario
  4. D.Monolithic applications are unable to scale at all

Explanation

Monolithic packages everything together, while microservices break it into independent services.

Report an error in this question

Server-Side ProgrammingHard

Q25. What is gRPC?

  1. A.A CSS framework for responsive web design
  2. B.A JavaScript library for building reactive interfaces
  3. C.A high-performance RPC framework using Protocol Buffers✓ Correct
  4. D.A relational database management system for apps

Explanation

gRPC uses Protocol Buffers for serialization and HTTP/2 for transport.

Report an error in this question

Server-Side ProgrammingHard

Q26. What is the circuit breaker pattern?

  1. A.A database locking mechanism for transaction isolation levels
  2. B.An electrical safety feature for server power
  3. C.A CSS layout pattern for organizing grid-based page elements
  4. D.A pattern preventing cascading failures by stopping failing requests✓ Correct

Explanation

The circuit breaker detects failures and prevents repeated attempts to a failing operation.

Report an error in this question

Server-Side ProgrammingHard

Q27. What is the difference between synchronous and asynchronous processing?

  1. A.Synchronous processing cannot handle any I/O operations
  2. B.Synchronous blocks until complete; asynchronous allows other ops✓ Correct
  3. C.They are identical in execution flow handling
  4. D.Asynchronous is always slower than synchronous code processing

Explanation

Synchronous blocks the thread, while asynchronous continues execution.

Report an error in this question

Server-Side ProgrammingHard

Q28. What is server-sent events (SSE)?

  1. A.A technology for pushing real-time updates over HTTP✓ Correct
  2. B.Server-side CSS events triggered by style changes
  3. C.A database trigger that fires on record modifications
  4. D.A JavaScript event system for handling user interactions

Explanation

SSE allows servers to push data to clients over a single HTTP connection.

Report an error in this question

Server-Side ProgrammingHard

Q29. What is the purpose of health check endpoints?

  1. A.Checking only database health and connection status
  2. B.Checking user health data in medical applications
  3. C.Checking CSS health for validation errors
  4. D.Providing a way for load balancers to verify server health✓ Correct

Explanation

Health check endpoints let load balancers route traffic away from unhealthy instances.

Report an error in this question

Server-Side ProgrammingHard

Q30. What is the Twelve-Factor App methodology?

  1. A.A database design pattern for normalized tables
  2. B.A CSS framework following twelve core principles
  3. C.A methodology for building scalable SaaS apps✓ Correct
  4. D.A 12-step coding tutorial for learning web dev

Explanation

The Twelve-Factor App defines best practices for building cloud-native applications.

Report an error in this question

Ready to test yourself on Server-Side Programming?

Take a timed quiz drawn from 210+ questions on this topic. No signup required — your progress saves in your browser.

Start Server-Side Programming Quiz