Join WhatsApp ChannelDaily MCQs & Exam Updates

Computer Science MCQs

MCQs on Programming, Networking, Database and OS

26 Questions
Subject Preparation Guide

Prepare Computer Science with confidence

Strengthen your knowledge of computer fundamentals, hardware, software, programming, networks, databases and information technology.

Computer BasicsProgrammingNetworksDatabases
Recommended for academic classes, IT tests and computer portions of competitive examinations.
Computer Science preparation illustration
21
Medium css pms

Which software development model follows a sequential approach?

  • A Agile
  • B Scrum
  • C Waterfall
  • D DevOps
Permalink
Correct Answer: Option C — Waterfall
Explanation: The Waterfall model progresses through defined phases in sequence and is suitable for stable requirements.
Submitted by: PaperMCQs
22
Medium css pms

What is the purpose of a foreign key?

  • A Store passwords
  • B Identify duplicate records
  • C Create relationships between tables
  • D Encrypt database contents
Permalink
Correct Answer: Option C — Create relationships between tables
Explanation: Foreign keys enforce relationships between tables and maintain referential integrity.
Submitted by: PaperMCQs
23
Medium css pms

What is polymorphism in object-oriented programming?

  • A Data hiding
  • B Ability of an object to take multiple forms
  • C Memory allocation
  • D Database indexing
Permalink
Correct Answer: Option B — Ability of an object to take multiple forms
Explanation: Polymorphism allows objects to be treated through a common interface while exhibiting different behaviors depending on their actual type.
Submitted by: PaperMCQs
24
Medium css pms

Which data structure is most suitable for implementing recursion?

  • A Queue
  • B Array
  • C Stack
  • D Heap
Permalink
Correct Answer: Option C — Stack
Explanation: Recursion relies on the call stack to store function calls, local variables, and return addresses. Every recursive call creates a new stack frame, which is removed when the function returns. This makes the stack the fundamental data structure behind recursion.
Submitted by: PaperMCQs
25
Medium css pms

What is encapsulation in object-oriented programming?

  • A Combining data and methods into a single unit
  • B Creating multiple classes
  • C Executing parallel processes
  • D Allocating memory dynamically
Permalink
Correct Answer: Option A — Combining data and methods into a single unit
Explanation: Encapsulation is the process of bundling data and methods within a class while restricting direct access to internal details. It improves modularity, maintainability, and security by controlling how data is accessed and modified.
Submitted by: PaperMCQs
26
Medium css pms

Which data structure follows the Last In First Out (LIFO) principle?

  • A Queue
  • B Array
  • C Stack
  • D Linked List
Permalink
Correct Answer: Option C — Stack
Explanation: A stack follows the Last In First Out principle, meaning the most recently added element is removed first. Stacks are widely used in function calls, recursion, expression evaluation, and memory management.
Submitted by: PaperMCQs