Join WhatsApp ChannelDaily MCQs & Exam Updates

Computer Science MCQs

MCQs on Programming, Networking, Database and OS

66 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
41
Medium css fpsc

What does VLOOKUP do in Excel?

  • A Creates charts
  • B Searches values vertically
  • C Deletes rows
  • D Sorts data
Permalink
Correct Answer: Option B — Searches values vertically
Explanation: VLOOKUP searches for a value in the first column of a table and returns related information from another column.
Submitted by: PaperMCQs
42
Medium fpsc ppsc

Which feature in Excel is used to summarize large datasets?

  • A Spell Check
  • B Pivot Table
  • C WordArt
  • D AutoFill
Permalink
Correct Answer: Option B — Pivot Table
Explanation: Pivot Tables allow users to summarize, analyze, and organize large amounts of data efficiently.
Submitted by: PaperMCQs
43
Easy fpsc nts

What is the role of DNS in networking?

  • A Assign IP addresses
  • B Translate domain names to IP addresses
  • C Transfer files
  • D Encrypt network traffic
Permalink
Correct Answer: Option B — Translate domain names to IP addresses
Explanation: DNS converts domain names into IP addresses, allowing systems to locate internet resources.
Submitted by: PaperMCQs
44
Medium fpsc ppsc

What is the primary purpose of RAID technology?

  • A Increase screen resolution
  • B Improve storage performance and reliability
  • C Enhance processor speed
  • D Manage network traffic
Permalink
Correct Answer: Option B — Improve storage performance and reliability
Explanation: RAID combines multiple drives to improve performance, fault tolerance, or both.
Submitted by: PaperMCQs
45
Medium css fpsc

Which of the following is a NoSQL database?

  • A Oracle
  • B MySQL
  • C MongoDB
  • D PostgreSQL
Permalink
Correct Answer: Option C — MongoDB
Explanation: MongoDB is a document-oriented NoSQL database designed for flexible and scalable data storage.
Submitted by: PaperMCQs
46
Hard css fpsc

What is a deadlock in an operating system?

  • A A memory leak
  • B A security attack
  • C A situation where processes wait indefinitely for resources
  • D A file corruption error
Permalink
Correct Answer: Option C — A situation where processes wait indefinitely for resources
Explanation: Deadlock occurs when processes are permanently blocked waiting for resources held by one another.
Submitted by: PaperMCQs
47
Medium css fpsc

What is the purpose of an index in a database?

  • A Reduce security
  • B Improve query performance
  • C Store backups
  • D Encrypt records
Permalink
Correct Answer: Option B — Improve query performance
Explanation: Indexes improve retrieval speed by allowing databases to locate records efficiently.
Submitted by: PaperMCQs
48
Medium css fpsc

Which memory is fastest among the following?

  • A Hard Disk
  • B RAM
  • C Cache Memory
  • D ROM
Permalink
Correct Answer: Option C — Cache Memory
Explanation: Cache memory stores frequently used data close to the CPU and is significantly faster than RAM.
Submitted by: PaperMCQs
49
Medium fpsc nts

Which SQL clause is used to filter rows before grouping?

  • A HAVING
  • B GROUP BY
  • C WHERE
  • D ORDER BY
Permalink
Correct Answer: Option C — WHERE
Explanation: The WHERE clause filters rows before grouping and aggregation are applied.
Submitted by: PaperMCQs
50
Hard css fpsc

Which algorithm is commonly used to find the shortest path in a weighted graph?

  • A Bubble Sort
  • B Dijkstra's Algorithm
  • C Binary Search
  • D Depth First Search
Permalink
Correct Answer: Option B — Dijkstra's Algorithm
Explanation: Dijkstra's Algorithm finds shortest paths in weighted graphs with non-negative edge weights and is widely used in navigation systems.
Submitted by: PaperMCQs
51
Medium css fpsc

Which OSI layer is responsible for end-to-end communication?

  • A Network Layer
  • B Data Link Layer
  • C Transport Layer
  • D Session Layer
Permalink
Correct Answer: Option C — Transport Layer
Explanation: The Transport Layer provides end-to-end communication, reliability, flow control, and error handling using protocols such as TCP and UDP.
Submitted by: PaperMCQs
52
Medium fpsc nts

Which sorting algorithm repeatedly selects the smallest element and places it in the correct position?

  • A Merge Sort
  • B Quick Sort
  • C Selection Sort
  • D Heap Sort
Permalink
Correct Answer: Option C — Selection Sort
Explanation: Selection Sort repeatedly finds the minimum element from the unsorted portion and places it at the beginning. It is simple but inefficient for large datasets.
Submitted by: PaperMCQs
53
Medium css fpsc

What is the primary purpose of normalization in relational databases?

  • A Increase redundancy
  • B Reduce redundancy
  • C Increase storage space
  • D Improve graphics rendering
Permalink
Correct Answer: Option B — Reduce redundancy
Explanation: Normalization organizes data into structured tables to minimize redundancy and dependency issues. It improves data integrity, reduces update anomalies, and makes databases easier to maintain and scale in real-world applications.
Submitted by: PaperMCQs
54
Medium fpsc ppsc

Which scheduling algorithm gives each process a fixed time slice?

  • A FCFS
  • B Round Robin
  • C Shortest Job First
  • D Priority Scheduling
Permalink
Correct Answer: Option B — Round Robin
Explanation: Round Robin scheduling assigns a fixed time quantum to each process. If a process does not complete within its allotted time, it is moved to the end of the queue. This approach improves fairness and responsiveness in time-sharing systems.
Submitted by: PaperMCQs
55
Medium css fpsc

What is the purpose of a firewall?

  • A Increase processor speed
  • B Protect networks from unauthorized access
  • C Store files permanently
  • D Compress data
Permalink
Correct Answer: Option B — Protect networks from unauthorized access
Explanation: A firewall monitors and filters network traffic according to predefined security rules. It acts as a barrier between trusted and untrusted networks, helping prevent unauthorized access and cyberattacks.
Submitted by: PaperMCQs
56
Easy fpsc nts

Which protocol translates domain names into IP addresses?

  • A HTTP
  • B FTP
  • C DNS
  • D SSH
Permalink
Correct Answer: Option C — DNS
Explanation: The Domain Name System (DNS) converts human-readable domain names into numerical IP addresses. This translation allows users to access websites using easy-to-remember names instead of complex numeric addresses.
Submitted by: PaperMCQs
57
Medium css fpsc

What is the time complexity of Binary Search in the worst case?

  • A O(n)
  • B O(log n)
  • C O(n²)
  • D O(1)
Permalink
Correct Answer: Option B — O(log n)
Explanation: Binary Search repeatedly divides a sorted dataset into halves until the target value is found or determined absent. Because the search space is halved each step, the worst-case time complexity is logarithmic, O(log n).
Submitted by: PaperMCQs
58
Medium css fpsc

Which layer of the OSI model is responsible for routing packets?

  • A Transport Layer
  • B Network Layer
  • C Session Layer
  • D Presentation Layer
Permalink
Correct Answer: Option B — Network Layer
Explanation: The Network Layer is responsible for logical addressing and routing of packets between networks. Protocols such as IP operate at this layer, enabling data to travel across interconnected networks efficiently.
Submitted by: PaperMCQs
59
Easy fpsc ppsc

Which device is responsible for connecting different networks together?

  • A Switch
  • B Hub
  • C Router
  • D Repeater
Permalink
Correct Answer: Option C — Router
Explanation: A router connects multiple networks and forwards data packets between them based on IP addresses. It determines the most efficient path for data transmission and plays a critical role in Internet communication.
Submitted by: PaperMCQs
60
Easy fpsc nts

Which protocol is primarily used for sending emails over the Internet?

  • A HTTP
  • B SMTP
  • C FTP
  • D DNS
Permalink
Correct Answer: Option B — SMTP
Explanation: Simple Mail Transfer Protocol (SMTP) is the standard protocol used for sending email messages between servers and from clients to servers. It works alongside protocols such as POP3 and IMAP, which are used for receiving emails.
Submitted by: PaperMCQs