Q182. What is external fragmentation in dynamic memory allocation?
⚪ Status: You Skipped this question
Correct Answer: Option A (Total free memory space is sufficient to satisfy a request, but it is not contiguous)
A
Total free memory space is sufficient to satisfy a request, but it is not contiguous
Correct Answer
B
Wasted memory inside allocated page frame
C
Disk space overflow
D
Cache tag mismatch
Why: External fragmentation occurs when small unallocated memory holes exist scattered throughout RAM, failing contiguous allocation requests.
Computer Networks & SubnettingNot attempted
Q183. Which Classless Inter-Domain Routing (CIDR) notation corresponds to the subnet mask 255.255.240.0?
⚪ Status: You Skipped this question
Correct Answer: Option A (/20)
A
/20
Correct Answer
B
/16
C
/24
D
/28
Why: 255.255.240.0 in binary has 8 + 8 + 4 = 20 network prefix bits, written as /20.
Computer Networks & SubnettingNot attempted
Q184. What is the primary role of NAT (Network Address Translation) routers?
⚪ Status: You Skipped this question
Correct Answer: Option A (To map private internal IP addresses to a public routable IP address for Internet access)
A
To map private internal IP addresses to a public routable IP address for Internet access
Correct Answer
B
To assign DNS hostnames
C
To format HTML documents
D
To compress video streams
Why: NAT allows local networks using RFC 1918 private IPs (192.168.x.x, 10.x.x.x) to share single public IP addresses.
Operating Systems & Disk SchedulingNot attempted
Q185. Which CPU scheduling algorithm prioritizes processes with the shortest burst time but can lead to starvation of long processes?
⚪ Status: You Skipped this question
Correct Answer: Option A (SJF (Shortest Job First))
A
SJF (Shortest Job First)
Correct Answer
B
FCFS
C
Round Robin
D
Priority Scheduling
Why: SJF minimizes average waiting time but continuously selects short jobs, starving long CPU-bound jobs if short jobs arrive continuously.
Operating Systems & Disk SchedulingNot attempted
Q186. In C-LOOK disk scheduling, how does the head move after reaching the last requested cylinder in one direction?
⚪ Status: You Skipped this question
Correct Answer: Option A (Jumps immediately to the lowest requested cylinder without servicing requests during return)
A
Jumps immediately to the lowest requested cylinder without servicing requests during return
Correct Answer
B
Reverses direction servicing requests on return path
C
Stops completely
D
Goes to cylinder 0
Why: C-LOOK (Circular LOOK) travels only as far as the last request in one direction, then immediately jumps back to the first request in the opposite end.
Data Structures & HashingNot attempted
Q187. What open addressing collision resolution technique probes locations h(k, i) = (h'(k) + c1*i + c2*i²) mod m?
Q188. What is the time complexity to insert an element into a Max Heap of n elements?
⚪ Status: You Skipped this question
Correct Answer: Option A (O(log n))
A
O(log n)
Correct Answer
B
O(n)
C
O(1)
D
O(n log n)
Why: Insertion appends element at array end and bubbles up along tree height log₂ n, taking O(log n) time.
Database Systems & Transaction IsolationNot attempted
Q189. In SQL transaction isolation levels, what is a Phantom Read?
⚪ Status: You Skipped this question
Correct Answer: Option A (Transaction re-executes query and finds new rows inserted by another committed transaction)
A
Transaction re-executes query and finds new rows inserted by another committed transaction
Correct Answer
B
Reading uncommitted dirty data
C
Reading modified data that changes on re-read
D
Database system crash
Why: Phantom read occurs when transaction T1 reads a set of rows matching search criteria, T2 inserts a new row matching criteria, and T1 re-reads getting extra rows.
Database Systems & Transaction IsolationNot attempted
Q190. Which transaction isolation level completely prevents Dirty Reads, Non-Repeatable Reads, and Phantom Reads?
⚪ Status: You Skipped this question
Correct Answer: Option A (SERIALIZABLE)
A
SERIALIZABLE
Correct Answer
B
READ COMMITTED
C
REPEATABLE READ
D
READ UNCOMMITTED
Why: SERIALIZABLE is the highest isolation level enforcing complete serial execution using range locks.
Correct Answer: Option A (I/O devices and RAM share the same address space and use identical memory instructions)
A
I/O devices and RAM share the same address space and use identical memory instructions
Correct Answer
B
I/O devices use separate dedicated IN/OUT bus instructions
C
I/O devices communicate only via interrupts
D
I/O devices bypass CPU
Why: In Memory-Mapped I/O, device registers occupy standard memory addresses accessed via MOV instructions.
Software Engineering & VerificationNot attempted
Q193. In software metrics, what does Halstead's Software Science measure?
⚪ Status: You Skipped this question
Correct Answer: Option A (Program length, volume, effort, and bugs based on total count of distinct operators and operands)
A
Program length, volume, effort, and bugs based on total count of distinct operators and operands
Correct Answer
B
Lines of text comments
C
Network bandwidth consumption
D
Hardware clock speed
Why: Halstead metrics calculate Program Volume V and Effort E using operator count (η1, N1) and operand count (η2, N2).
Software Engineering & VerificationNot attempted
Q194. What is Alpha Testing in software development life cycle?
⚪ Status: You Skipped this question
Correct Answer: Option A (Internal acceptance testing performed by developers/testers at the developer's site)
A
Internal acceptance testing performed by developers/testers at the developer's site
Correct Answer
B
Testing performed by end-users at their own site
C
Unit testing of single function
D
Stress testing database under load
Why: Alpha testing is conducted internally at developer site before releasing Beta versions to external users.
Theory of Computation & GrammarsNot attempted
Q195. What is a Greibach Normal Form (GNF) context-free grammar?
⚪ Status: You Skipped this question
Correct Answer: Option A (All production rules are of the form A → aα (starts with single terminal followed by string of non-terminals))
A
All production rules are of the form A → aα (starts with single terminal followed by string of non-terminals)
Correct Answer
B
All rules are A → BC
C
All rules are A → ε
D
All rules have terminal on right side
Why: GNF grammar rules start with exactly one terminal symbol followed by 0 or more non-terminals (A → a V*).
Theory of Computation & GrammarsNot attempted
Q196. What is Chomsky Normal Form (CNF) for Context-Free Grammars?
⚪ Status: You Skipped this question
Correct Answer: Option A (Production rules are strictly of form A → BC or A → a)
A
Production rules are strictly of form A → BC or A → a
Correct Answer
B
Production rules are A → aα
C
Production rules are A → B
D
Production rules are A → aBCd
Why: CNF rules restrict right-hand side to either exactly 2 non-terminals (A → BC) or 1 single terminal (A → a).
Compiler Design & Intermediate CodeNot attempted
Q197. What is Loop Unrolling in compiler code optimization?
⚪ Status: You Skipped this question
Correct Answer: Option A (Replicating loop body instructions to reduce loop control overhead and branch tests)
A
Replicating loop body instructions to reduce loop control overhead and branch tests
Correct Answer
B
Moving loop outside function
C
Deleting loop body
D
Converting loop into recursion
Why: Loop unrolling expands loop iterations inline to decrease branch checks and exploit instruction-level parallelism.
Compiler Design & Intermediate CodeNot attempted
Q198. What is Peephole Optimization in compiler design?
⚪ Status: You Skipped this question
Correct Answer: Option A (Local optimization technique analyzing a small moving window (peephole) of target code instructions)
A
Local optimization technique analyzing a small moving window (peephole) of target code instructions
Correct Answer
B
Global data flow analysis
C
Syntax tree construction
D
Lexical tokenization
Why: Peephole optimization examines small target code sequences to remove redundant loads/stores and algebraic identities.
Memory Management & Virtual MemoryNot attempted
Q199. In page table structures, what is an Inverted Page Table?
⚪ Status: You Skipped this question
Correct Answer: Option A (Page table indexed by physical frame number containing one entry per physical RAM frame)
A
Page table indexed by physical frame number containing one entry per physical RAM frame
Correct Answer
B
Page table stored on disk
C
Page table indexed by virtual page number per process
D
Cache table
Why: Inverted Page Table maintains fixed size equal to physical memory frames, saving massive memory overhead in 64-bit systems.
Computer Networks & SubnettingNot attempted
Q200. What is the primary function of the Border Gateway Protocol (BGP)?
⚪ Status: You Skipped this question
Correct Answer: Option A (Inter-Autonomous System (Inter-AS) routing across the global Internet backbone)
A
Inter-Autonomous System (Inter-AS) routing across the global Internet backbone
Correct Answer
B
Local Ethernet MAC switching
C
Dynamic IP address allocation on LAN
D
File transfer protocol
Why: BGP is the standardized Exterior Gateway Protocol (EGP) managing path-vector routing between Autonomous Systems (ISPs).
Operating Systems & Disk SchedulingNot attempted
Q201. What is a Critical Section in concurrent programming?
⚪ Status: You Skipped this question
Correct Answer: Option A (Code segment accessing shared variables or resources that must NOT be executed concurrently by multiple processes)
A
Code segment accessing shared variables or resources that must NOT be executed concurrently by multiple processes
Correct Answer
B
Boot code section
C
Compiler syntax error block
D
Memory allocation table
Why: Critical Section accesses shared state requiring Mutual Exclusion to avoid Race Conditions.
Data Structures & HashingNot attempted
Q202. What is the worst-case search time complexity in a Red-Black Tree with n nodes?
⚪ Status: You Skipped this question
Correct Answer: Option A (O(log n))
A
O(log n)
Correct Answer
B
O(n)
C
O(1)
D
O(n log n)
Why: Red-Black Tree maintains height bounded by 2 log₂(n + 1), guaranteeing O(log n) search, insert, and delete.
Database Systems & Transaction IsolationNot attempted
Q203. What is the difference between TRUNCATE and DELETE in SQL?
⚪ Status: You Skipped this question
Correct Answer: Option A (TRUNCATE is DDL command removing all rows fast without logging individual row deletes; DELETE is DML command removing selected rows with logging)
A
TRUNCATE is DDL command removing all rows fast without logging individual row deletes; DELETE is DML command removing selected rows with logging
Correct Answer
B
DELETE deletes table structure
C
TRUNCATE applies WHERE clause
D
They are identical
Why: TRUNCATE resets data pages without row logging (DDL, faster). DELETE logs each row deletion allowing rollback (DML, WHERE allowed).
Q208. Which IPv4 address range is designated for private local networks under RFC 1918?
⚪ Status: You Skipped this question
Correct Answer: Option A (10.0.0.0/8, 172.16.0.0/12, 192.168.0.0/16)
A
10.0.0.0/8, 172.16.0.0/12, 192.168.0.0/16
Correct Answer
B
127.0.0.0/8 only
C
224.0.0.0/4 only
D
1.1.1.0/24
Why: RFC 1918 defines private non-routable IP ranges: 10.0.0.0–10.255.255.255, 172.16.0.0–172.31.255.255, and 192.168.0.0–192.168.255.255.
Operating Systems & Disk SchedulingNot attempted
Q209. In Unix file systems, what is an inode?
⚪ Status: You Skipped this question
Correct Answer: Option A (Data structure storing file metadata like file size, permissions, owner ID, and data block pointers)
A
Data structure storing file metadata like file size, permissions, owner ID, and data block pointers
Correct Answer
B
The actual text contents of file
C
Directory path string
D
Swap file partition
Why: An inode (index node) stores all metadata about a file except its name and actual content data.
Data Structures & HashingNot attempted
Q210. What is the worst-case space complexity of storing a directed graph with V vertices using an Adjacency Matrix?
⚪ Status: You Skipped this question
Correct Answer: Option A (O(V²))
A
O(V²)
Correct Answer
B
O(V + E)
C
O(E²)
D
O(V log V)
Why: An Adjacency Matrix allocates a V x V 2D array regardless of the number of edges E, taking O(V²) space.
Database Systems & Transaction IsolationNot attempted
Q211. In relational database indexing, what is a Clustered Index?
⚪ Status: You Skipped this question
Correct Answer: Option A (An index that defines the physical order of data rows on disk (only one clustered index per table))
A
An index that defines the physical order of data rows on disk (only one clustered index per table)
Correct Answer
B
A secondary index on non-key columns
C
A hash table index
D
A temporary index stored in RAM
Why: Clustered index physically sorts data rows on disk according to the key values. Since physical rows can have only one order, a table can have only 1 clustered index.
Correct Answer: Option A (Special hardware/software function executed automatically when an interrupt is triggered)
A
Special hardware/software function executed automatically when an interrupt is triggered
Correct Answer
B
A loop inside compiler
C
A database query handler
D
A page fault replacement algorithm
Why: ISR (Interrupt Handler) handles asynchronous hardware/software interrupt requests by saving process context and servicing the event.
Software Engineering & VerificationNot attempted
Q213. In Object-Oriented Analysis, what does an Object Sequence Diagram represent?
⚪ Status: You Skipped this question
Correct Answer: Option A (Temporal order of message exchanges between objects over time)
A
Temporal order of message exchanges between objects over time
Correct Answer
B
Static database structure
C
Source code file directory structure
D
Network IP routing topology
Why: UML Sequence Diagrams visualize dynamic interaction and message calls between instances along a vertical lifeline.
Theory of Computation & GrammarsNot attempted
Q214. Which language family is closed under complementation?
⚪ Status: You Skipped this question
Correct Answer: Option A (Regular Languages)
A
Regular Languages
Correct Answer
B
Context-Free Languages
C
Recursively Enumerable Languages (Semi-Decidable)
D
Nondeterministic Pushdown Languages
Why: Regular Languages are closed under complementation (by swapping final and non-final states in DFA). Context-Free languages are NOT closed under complementation.
Compiler Design & Intermediate CodeNot attempted
Q215. What is Dead Code Elimination in compiler optimization?
⚪ Status: You Skipped this question
Correct Answer: Option A (Removing instructions whose results are never used or that can never be executed)
A
Removing instructions whose results are never used or that can never be executed
Correct Answer
B
Deleting header comments
C
Converting local variables to global
D
Removing static functions
Why: Dead Code Elimination detects unreachable code or variables written but never read, stripping them from final binary.
Computer Networks & SubnettingNot attempted
Q216. Which layer of the OSI model manages data compression, encryption, and syntax translation?
⚪ Status: You Skipped this question
Correct Answer: Option A (Presentation Layer (Layer 6))
A
Presentation Layer (Layer 6)
Correct Answer
B
Session Layer (Layer 5)
C
Application Layer (Layer 7)
D
Transport Layer (Layer 4)
Why: Layer 6 (Presentation Layer) handles string encoding (ASCII/Unicode), encryption (SSL/TLS), and data compression.
Operating Systems & Disk SchedulingNot attempted
Q217. What is a Context Switch in operating systems?
⚪ Status: You Skipped this question
Correct Answer: Option A (Saving the state of currently running process and restoring state of another process to resume execution)
A
Saving the state of currently running process and restoring state of another process to resume execution
Correct Answer
B
Switching off monitor display
C
Changing compiler optimization level
D
Translating Java bytecode
Why: Context Switching saves PCB registers/pointers of current process and loads PCB of next process scheduled by CPU scheduler.
Data Structures & HashingNot attempted
Q218. What is the amortized time complexity of push() operation in a dynamic array (like C++ std::vector)?
⚪ Status: You Skipped this question
Correct Answer: Option A (O(1))
A
O(1)
Correct Answer
B
O(n)
C
O(log n)
D
O(n²)
Why: Dynamic arrays double capacity on overflow. Doubling cost O(n) happens rarely, averaging out to O(1) amortized time per insertion.
Database Systems & Transaction IsolationNot attempted
Q219. In relational algebra, what is Division operation (R ÷ S) used for?
⚪ Status: You Skipped this question
Correct Answer: Option A (Queries involving 'FOR ALL' or 'EVERY' requirements (e.g. Find students who registered for ALL courses))
A
Queries involving 'FOR ALL' or 'EVERY' requirements (e.g. Find students who registered for ALL courses)
Correct Answer
B
Dividing numeric values
C
Sorting relation rows
D
Calculating average
Why: Division (R ÷ S) selects tuples in R that are associated with EVERY tuple in relation S.
Q228. In Computer Organization, what is a RISC Superscalar Architecture?
⚪ Status: You Skipped this question
Correct Answer: Option A (Processor architecture capable of issuing and executing multiple independent instructions simultaneously per clock cycle using parallel execution pipelines)
A
Processor architecture capable of issuing and executing multiple independent instructions simultaneously per clock cycle using parallel execution pipelines
Correct Answer
B
Single instruction execution per 10 clock cycles
C
Software emulation mode
D
Microcoded ROM execution
Why: Superscalar CPUs duplicate execution units (ALUs, FPUs) allowing CPI < 1 by executing 2 or more instructions in parallel per clock cycle.
Software Engineering & VerificationNot attempted
Q229. In software engineering, what is Equivalence Partitioning in Black Box Testing?
⚪ Status: You Skipped this question
Correct Answer: Option A (Dividing input domain into classes of data from which test cases can be derived, assuming all items in a class behave identically)
A
Dividing input domain into classes of data from which test cases can be derived, assuming all items in a class behave identically
Correct Answer
B
Testing source code lines
C
Executing all loops 10 times
D
Sorting test cases alphabetically
Why: Equivalence Partitioning reduces total test case count by picking 1 representative value from each valid/invalid input group.
Theory of Computation & GrammarsNot attempted
Q230. What is the Church-Turing Thesis?
⚪ Status: You Skipped this question
Correct Answer: Option A (Hypothesis stating that any effectively calculable function can be computed by a Turing Machine)
A
Hypothesis stating that any effectively calculable function can be computed by a Turing Machine
Q236. In Flynn's Taxonomy of Computer Architecture, what does SIMD stand for?
⚪ Status: You Skipped this question
Correct Answer: Option A (Single Instruction Multiple Data)
A
Single Instruction Multiple Data
Correct Answer
B
Sequential Instruction Multi Drive
C
System Integrated Memory Device
D
Shared Instruction Matrix Processor
Why: SIMD architecture (used in GPUs and vector extensions like SSE/AVX) executes 1 instruction across multiple data streams simultaneously.
Software Engineering & VerificationNot attempted
Q237. In software engineering, what is the main purpose of Software Configuration Management (SCM)?
⚪ Status: You Skipped this question
Correct Answer: Option A (Tracking, controlling, and managing changes to code, artifacts, and documentation across software versions)
A
Tracking, controlling, and managing changes to code, artifacts, and documentation across software versions
Correct Answer
B
Buying hardware servers
C
Writing user manuals
D
Testing SQL queries
Why: SCM tools (like Git, SVN) maintain baseline configurations, branch management, and revision history across releases.
Theory of Computation & GrammarsNot attempted
Q238. Which of the following decision problems is UNDECIDABLE for Context-Free Grammars?
⚪ Status: You Skipped this question
Correct Answer: Option A (Is L(G1) ∩ L(G2) = ∅? (Disjointness problem for two CFGs))
A
Is L(G1) ∩ L(G2) = ∅? (Disjointness problem for two CFGs)
Correct Answer
B
Is string w in L(G)? (Membership problem)
C
Is L(G) = ∅? (Emptiness problem)
D
Is L(G) infinite? (Finiteness problem)
Why: For Context-Free Grammars, checking if their intersection is empty is UNDECIDABLE (proven via Post Correspondence Problem reduction). Membership, emptiness, and finiteness are decidable for CFGs.
Compiler Design & Intermediate CodeNot attempted
Q239. What is an Activation Record (Stack Frame) in runtime environment management?
⚪ Status: You Skipped this question
Correct Answer: Option A (A contiguous block of stack memory allocated upon a function call storing parameters, local variables, return address, and saved registers)
A
A contiguous block of stack memory allocated upon a function call storing parameters, local variables, return address, and saved registers
Correct Answer
B
A global heap memory block
C
A CPU register file
D
A disk swap block
Why: Each function execution creates an Activation Record on the runtime call stack containing return address, local data, and control links.
Computer Networks & SubnettingNot attempted
Q240. In Computer Networks, what is the Maximum Segment Size (MSS) in TCP header negotiation?
⚪ Status: You Skipped this question
Correct Answer: Option A (Largest amount of TCP payload data (in bytes) a host can receive in a single unfragmented segment)
A
Largest amount of TCP payload data (in bytes) a host can receive in a single unfragmented segment
Correct Answer
B
Total size of IP header
C
Size of Ethernet MAC frame
D
Maximum ping round trip time
Why: MSS = MTU - (IP Header + TCP Header). For standard Ethernet MTU 1500 bytes: MSS = 1500 - 20 - 20 = 1460 bytes.
UPPSC Polytechnic Computer Lecturer Verified PYQ Mock Test | LastDayPrep