C Programming & Data StructuresDatabase Management Systems (DBMS) & SQLWeb Technologies & Internet ProtocolsObject Oriented Programming (C++, Java, C#)Software Engineering & SDLCOperating Systems & System Software
📝 Solved Questions with Detailed Explanations100% Free • No Login Required
Mode: Interactive Practice (Click any option to test yourself)
JKSSB — Junior Programmer (2025)
Information Technology Department • Official Examination Solved Question Booklet
Total Questions: 120Maximum Marks: 120Time Allowed: 120 Minutes
C Programming & Data StructuresArrays & Pointer Arithmetic in C
What will be the output of the following code?
```c #include <stdio.h> int main() { int arr[3] = {1, 2, 3}; printf("%d ", 2[arr]); return 0; } ```
💡Correct Answer: Option C (3)
In C, array subscript notation is commutative: `arr[2]` is equivalent to `(arr + 2)`, which is identical to `(2 + arr)` or `2[arr]`. Since `arr[2] == 3`, the code outputs `3`.
Q2
C Programming & Data StructuresControl Structures & Null Statements
What will be the output of this code?
```c #include <stdio.h> int main() { int a = 5; if (a == 5) printf("Hello"); else; printf("World!"); return 0; } ```
💡Correct Answer: Option B (Hello World!)
Since `a == 5` is true, `printf("Hello");` executes. The `else;` has a semicolon, making it a null statement. Thus, the subsequent statement `printf("World!");` is not part of the `else` branch and always executes. Output is `Hello World!`.
Q3
C Programming & Data StructuresDynamic Memory Allocation (malloc vs calloc)
Which of the following statements about malloc and calloc is correct?
💡Correct Answer: Option C (Calloc initializes memory to zero, but malloc does not.)
`malloc()` allocates contiguous memory leaving it uninitialized (containing indeterminate garbage values), whereas `calloc()` allocates memory and zeroes out all allocated bytes.
Q4
C Programming & Data StructuresPointers & Dereferencing in C
What is the output of the following code?
```c #include <stdio.h> int main() { int x = 5; int y = 10; int p = &x;
p += y; printf("%d %d ", x, y); return 0; } ```
💡Correct Answer: Option A (15 10)
`p` points to `x`. `*p += y` adds the value of `y` (10) to `x` (5), making `x = 15`. `y` remains 10. Output is `15 10`.
Q5
C Programming & Data StructuresFunction Pointers in C
Which of the following is a correct declaration of a pointer to a function in C?
💡Correct Answer: Option B (int (*func)(int a);)
A function pointer returning `int` and accepting `int a` is declared with parentheses around the pointer symbol: `int (func)(int a);` (or `int (func)(int);`). Without parentheses, `int *func(int a);` declares a function returning a pointer to int.
Q6
C Programming & Data StructuresNull Pointer Dereference & Segmentation Fault
What does the following code print?
```c #include <stdio.h> void func() { int p = NULL;
p = 10; } int main() { func(); return 0; } ```
💡Correct Answer: Option C (Segmentation fault)
Dereferencing a NULL pointer (`*p = 10`) attempts to write to an invalid memory location (address 0x0), which causes an OS memory access violation resulting in a Segmentation Fault (and undefined behavior).
Q7
C Programming & Data StructuresStructure Padding & Memory Alignment
What is the size of the following structure?
```c struct Test { char a; int b; char c; }; ```
💡Correct Answer: Option C (12 bytes)
Due to structure padding and 4-byte integer alignment on 32/64-bit systems: - `char a`: 1 byte + 3 bytes padding = 4 bytes - `int b`: 4 bytes = 4 bytes - `char c`: 1 byte + 3 bytes tail padding = 4 bytes Total size = 12 bytes.
Q8
C Programming & Data StructuresFormatted I/O in C
Which of the following statements about printf is correct?
Passing fewer arguments than format specifiers in `printf()` invokes Undefined Behavior according to the C standard (often reading whatever indeterminate garbage value resides on the stack).
Q9
C Programming & Data StructuresDynamic Memory Allocation
Which of the following functions is used to dynamically allocate memory in C?
💡Correct Answer: Option A (malloc())
`malloc()` (memory allocation) in `<stdlib.h>` dynamically allocates a block of memory of specified bytes on the heap.
Q10
C Programming & Data StructuresJump Statements (break & continue)
What is the purpose of the break statement in a loop?
💡Correct Answer: Option C (To exit the loop)
The `break` statement immediately terminates execution of the enclosing innermost loop (or `switch` block) and transfers control to the statement following the loop.
Q11
C Programming & Data StructuresLoops in C (do-while)
Which loop is guaranteed to execute at least once in C?
💡Correct Answer: Option C (do-while)
The `do-while` loop is an exit-controlled loop where the condition is evaluated after executing the loop body, guaranteeing at least one execution.
Q12
C Programming & Data StructuresPrimitive Data Types Sizes
Match the following data types in Column A with their corresponding sizes (in bytes) on a 32 bit system in Column B:
| Column - A | Column - B | | :--- | :--- | | 1. int | ii. 4 bytes | | 2. char | i. 1 byte | | 3. float | iii. 4 bytes | | 4. double | iv. 8 bytes |
Choose the correct options:
💡Correct Answer: Option A (1-ii, 2-i, 3-iii, 4-iv)
Sizes on a standard 32-bit system: int = 4 bytes (ii), char = 1 byte (i), float = 4 bytes (iii), double = 8 bytes (iv). Code: 1-ii, 2-i, 3-iii, 4-iv.
Q13
C Programming & Data StructuresC Functions & Recursion
Consider the following statements about functions in C: 1. Functions can return only one value. 2. Recursive functions can call themselves. 3. The void keyword is used to indicate that a function does not return a value. 4. Functions must always have a return type specified.
Choose the correct Statement:
💡Correct Answer: Option A (1, 2, and 3 are correct)
Statements 1, 2, and 3 are correct. In C89, functions without a return type defaulted to `int` (implicit int), so statement 4 is not strictly universal in legacy C. Thus, 1, 2, and 3 are correct.
Q14
C Programming & Data StructuresControl Structures (if-else, switch, loops)
Consider the following statements about control structures in C: 1. The if-else structure is used for conditional execution of code. 2. The switch statement must always have a default case. 3. The for loop is used when the number of iterations is known beforehand. 4. The while loop can execute zero or more times based on the condition.
Choose the correct Statement:
💡Correct Answer: Option B (1, 3, and 4 are correct)
Statements 1, 3, and 4 are correct. Statement 2 is false because the `default` label in a `switch` statement is completely optional.
Q15
C Programming & Data StructuresFile Handling in C
Match the following file-handling functions in Column A with their functionalities in Column B:
| Column - A | Column - B | | :--- | :--- | | 1. fopen() | iii. Opens a file | | 2. fclose() | ii. Closes an open file | | 3. fwrite() | iv. Writes data to a file | | 4. fread() | i. Reads data from a file |
Choose the correct options:
💡Correct Answer: Option A (1-iii, 2-ii, 3-iv, 4-i)
Matching: fopen() opens a file (iii); fclose() closes a file (ii); fwrite() writes binary data to a file (iv); fread() reads binary data from a file (i). Code: 1-iii, 2-ii, 3-iv, 4-i.
Q16
Database Management Systems (DBMS) & SQLRelational Data Model
Which of the following is a property of the relational database model?
💡Correct Answer: Option C (Data is organized in tuples and attributes)
In the relational model (RDBMS), data is logically represented as relations (tables) composed of tuples (rows/records) and attributes (columns/fields).
Q17
Database Management Systems (DBMS) & SQLSQL Aggregate Functions (COUNT)
What is the result of the following SQL query?
```sql SELECT COUNT(*) FROM Employee WHERE Salary > 50000; ```
💡Correct Answer: Option A (The number of employees with a salary greater than 50,000)
`COUNT(*)` aggregates and returns the total number of matching rows in the `Employee` table where `Salary > 50000`.
Q18
Database Management Systems (DBMS) & SQLACID Properties of Transactions
Which of the following is NOT a characteristic of transactions in DBMS?
💡Correct Answer: Option D (Divisibility)
Transaction properties are governed by ACID (Atomicity, Consistency, Isolation, Durability). 'Divisibility' contradicts the fundamental principle of Atomicity (all-or-nothing execution).
Q19
Database Management Systems (DBMS) & SQLDatabase Normalization (1NF, 2NF, 3NF)
Which of the following statements about normalization are correct? 1. Normalization reduces redundancy in a database 2. Normalization increases data integrity 3. Third Normal Form (3NF) removes transitive dependencies 4. First Normal Form (1NF) ensures data is atomic
Choose the correct options:
💡Correct Answer: Option C (1, 2, 3, and 4)
All 4 statements are correct: Normalization eliminates duplicate data (1), maintains data integrity (2), 3NF eliminates transitive dependencies (X→Y,Y→Z) (3), and 1NF enforces atomic, non-composite, single-valued attributes (4).
Q20
Database Management Systems (DBMS) & SQLDatabase Keys & Constraints
Match the following database terms with their descriptions:
| Term | Description | | :--- | :--- | | i. Primary Key | 1. Uniquely identifies a record | | ii. Foreign Key | 2. Enforces referential integrity | | iii. Candidate Key | 3. Can be a primary key | | iv. Composite Key | 4. Made up of multiple attributes |
Choose the correct options:
💡Correct Answer: Option A (i-1, ii-2, iii-3, iv-4)
Matching: i) Primary Key uniquely identifies a row (1); ii) Foreign Key enforces referential integrity between relations (2); iii) Candidate Key is a minimal superkey capable of being selected as primary key (3); iv) Composite Key consists of two or more attributes (4). Code: i-1, ii-2, iii-3, iv-4.
Q21
Database Management Systems (DBMS) & SQLQuery Processing & Optimization Steps
Arrange the following steps in query processing in the correct order: 1. Query Optimization 2. Query Parsing 3. Execution Plan Generation 4. Query Execution
Choose the correct options:
💡Correct Answer: Option A (2 → 1 → 3 → 4)
DBMS Query Processing Pipeline: 1. Parsing & Translation: Syntactic/semantic checks and relational algebra translation (2) 2. Query Optimization: Cost-based evaluation of query trees (1) 3. Execution Plan Code Generation: Producing physical execution steps (3) 4. Query Execution: Evaluating the plan by the query execution engine (4). Order: 2 → 1 → 3 → 4.
Q22
Web Technologies & Internet ProtocolsCSS Stacking Order & z-index
What does the z-index property in CSS determine?
💡Correct Answer: Option C (The stack order of an element)
The `z-index` property in CSS controls the vertical 3D stacking order of overlapping positioned elements along the z-axis (higher values render in front of lower values).
Q23
Database Management Systems (DBMS) & SQLCandidate Keys & Functional Dependencies
A table has 5 attributes. If the table is in 1NF, how many candidate keys can it have?
💡Correct Answer: Option D (Depends on the table)
The number of candidate keys is determined by the functional dependencies (FDs) between attributes, which varies from 1 up to many combinations depending on the relation's semantic schema.
Q24
Database Management Systems (DBMS) & SQLDatabase Indexing Pros & Cons
Which of the following are advantages of indexing in a database? 1. Improves query performance 2. Reduces storage requirements 3. Increases the speed of updates and inserts 4. Enables faster retrieval of rows
Choose the correct options:
💡Correct Answer: Option A (1 and 4)
Indexing speeds up SELECT query performance (1) and accelerates row retrieval (4). However, indexes consume additional disk storage space and slow down INSERT/UPDATE/DELETE operations because the index tree must be updated.
Q25
Database Management Systems (DBMS) & SQLSQL DML Commands
Match the following SQL commands with their purposes:
| SQL Command | Purpose | | :--- | :--- | | i. SELECT | 1. Retrieve data | | ii. INSERT | 2. Add new rows | | iii. UPDATE | 3. Modify existing data | | iv. DELETE | 4. Remove data |
Choose the correct options:
💡Correct Answer: Option A (i-1, ii-2, iii-3, iv-4)
Database Management Systems (DBMS) & SQLSQL Fundamentals
What does SQL stand for?
💡Correct Answer: Option C (Structured Query Language)
SQL stands for Structured Query Language, the standard domain-specific language used for managing data held in relational database management systems.
Q28
Web Technologies & Internet ProtocolsHTTP vs HTTPS Protocols
Which of the following statements about HTTP and HTTPS are correct? 1. HTTP sends data in plain text, whereas HTTPS encrypts data 2. HTTPS requires an SSL/TLS certificate 3. HTTPS operates on port 443, whereas HTTP operates on port 80 4. HTTPS is faster than HTTP because of encryption
Choose the correct options:
💡Correct Answer: Option A (1, 2, and 3)
Statements 1, 2, and 3 are correct. Statement 4 is false because TLS cryptographic handshake and encryption/decryption add a slight computational latency overhead, making HTTPS slightly more resource-intensive than unencrypted HTTP.
Which of the following statements about foreign keys are true? 1. A foreign key can have duplicate values 2. A foreign key must refer to a primary key in another table 3. A foreign key ensures referential integrity 4. A foreign key value cannot be NULL
Choose the correct options:
💡Correct Answer: Option A (1, 2, and 3)
Statements 1, 2, and 3 are true. Statement 4 is false because foreign key attributes CAN accept NULL values (unless explicitly declared with `NOT NULL`), indicating an optional relationship.
Q30
Database Management Systems (DBMS) & SQLDatabase Design Lifecycle
Arrange the following operations in the correct order for database design: 1. Requirement Analysis 2. Conceptual Design 3. Logical Design 4. Physical Design
Choose the correct options:
💡Correct Answer: Option A (1 → 2 → 3 → 4)
Standard phases of Database Design: 1. Requirement Analysis: Collecting data/functional user needs (1) 2. Conceptual Design: Entity-Relationship (ER) modeling (2) 3. Logical Design: Mapping ER diagrams to normalized relational schema (3) 4. Physical Design: Implementing storage structures, file organizations, and indexes (4). Order: 1 → 2 → 3 → 4.
Q31
C Programming & Data StructuresDoubly vs Singly Linked Lists
Which of the following operations is performed more efficiently by a doubly linked list than by a singly linked list?
💡Correct Answer: Option B (Deletion of the last node)
In a doubly linked list with a tail pointer, deleting the last node takes O(1) time because the `prev` pointer directly accesses the second-to-last node. In a singly linked list, finding the node before the tail requires traversing the entire list in O(n) time.
Q32
C Programming & Data StructuresBinary Tree Height & Properties
The height of a complete binary tree with n nodes is given by:
💡Correct Answer: Option B (\lfloor$\log$_{2}(n+1)\rfloor)
The height of a complete binary tree with n nodes (measured as number of levels or edges) is ⌊log2(n)⌋ or ⌊log2(n+1)⌋.
Q33
C Programming & Data StructuresHashing & Linear Probing
A hash table with 10 slots uses open addressing with linear probing. What is the average time complexity for an unsuccessful search?
💡Correct Answer: Option B (O(n))
In linear probing open addressing, primary clustering can form long contiguous occupied blocks, leading to an average/worst-case unsuccessful search complexity of O(n).
Q34
C Programming & Data StructuresAVL Trees & Balance Factor
Which of the following statements about AVL trees are correct? 1. AVL trees are height-balanced binary search trees 2. AVL trees allow duplicate elements 3. The balance factor of any node in an AVL tree is either -1, 0, or 1 4. Insertion in an AVL tree may require rebalancing
Choose the correct options:
💡Correct Answer: Option B (1, 3, and 4)
Statements 1, 3, and 4 are correct. Standard AVL trees enforce strict BST uniqueness (statement 2 is false). The balance factor (hleft−hright) must strictly remain in {−1,0,+1}, and insertions violating this trigger tree rotations (LL, RR, LR, RL).
Q35
C Programming & Data StructuresCore Data Structures & Properties
Match the following data structures with their properties:
| Data Structure | Property | | :--- | :--- | | i. Stack | 1. Last-In-First-Out (LIFO) | | ii. Queue | 2. First-In-First-Out (FIFO) | | iii. Binary Search Tree | 3. Efficient search operations | | iv. Hash Table | 4. Uses hash functions for fast access |
Choose the correct options:
💡Correct Answer: Option A (i-1, ii-2, iii-3, iv-4)
C Programming & Data StructuresMax Heap Insertion Algorithm
Arrange the following steps for inserting an element into a max heap in the correct order: 1. Place the element at the next available position 2. Compare the element with its parent 3. Swap the element with its parent if it is greater 4. Repeat until the heap property is restored
Choose the correct options:
💡Correct Answer: Option A (1 → 2 → 3 → 4)
Max Heap insertion (Heapify-Up/Bubble-Up): 1. Insert element at the bottom-most leftmost available leaf position (1) 2. Compare newly added element with its parent node (2) 3. If inserted element > parent, swap them (3) 4. Repeat bubble-up comparison until parent ≥ child or root is reached (4). Order: 1 → 2 → 3 → 4.
Q37
C Programming & Data StructuresBinary Search Tree Time Complexities
What is the time complexity of searching for an element in a balanced binary search tree (BST)?
💡Correct Answer: Option B (O(log n))
In a balanced BST (like AVL or Red-Black Tree), the height is guaranteed to be O(logn), making search, insertion, and deletion operations O(logn).
Q38
Web Technologies & Internet ProtocolsHTML Document Structure & Meta Tags
What is the purpose of the <meta> tag in HTML?
💡Correct Answer: Option B (To add metadata like description and keywords)
The `<meta>` tag in the HTML `<head>` specifies metadata such as character encoding (`charset`), page description, viewport configurations, SEO keywords, and author information.
Q39
C Programming & Data StructuresGraph Theory & Representations
Which of the following statements about graphs are correct? 1. A complete graph contains all possible edges between nodes. 2. In a directed graph, edges have a direction. 3. A graph can be represented using an adjacency matrix or adjacency list. 4. Depth-first search (DFS) is not applicable to cyclic graphs.
Choose the correct options:
💡Correct Answer: Option A (1, 2, and 3)
Statements 1, 2, and 3 are correct. Statement 4 is false because DFS handles cyclic graphs easily by maintaining a boolean visited array to avoid infinite loops. Thus, 1, 2, and 3 are correct.
Q40
C Programming & Data StructuresTree & Graph Traversals (DFS, BFS, Inorder, Postorder)
Match the following traversal algorithms with their applications:
| Traversal Algorithm | Application | | :--- | :--- | | i. Depth-First Search | 1. Solving mazes | | ii. Breadth-First Search | 2. Finding shortest path in unweighted graphs | | iii. In-order Traversal | 3. Traversing a binary search tree in sorted order | | iv. Post-order Traversal | 4. Evaluating expression trees |
Choose the correct options:
💡Correct Answer: Option B (i-1, ii-2, iii-3, iv-4)
Matching: DFS = backtracking/solving mazes (1); BFS = shortest path in unweighted graphs (2); In-order = sorted retrieval of BST nodes (3); Post-order = postfix evaluation of expression trees / bottom-up cleanup (4). Code: i-1, ii-2, iii-3, iv-4.
Q41
C Programming & Data StructuresBinary Search Tree Deletion
Arrange the following steps for deleting a node from a binary search tree (BST) in the correct order: 1. Find the node to be deleted 2. Replace the node with its in-order successor if it has two children 3. Delete the node if it has no children or one child 4. Rebalance the tree if necessary
Choose the correct options:
💡Correct Answer: Option A (1 → 2 → 3 → 4)
BST node deletion steps: 1 (Locate target node) → 2 (If node has 2 children, find and replace with in-order successor/predecessor) → 3 (Splice/delete node with 0 or 1 child) → 4 (Update heights/rebalance if self-balancing BST). Order: 1 → 2 → 3 → 4.
Q42
C Programming & Data StructuresCall Stack & Recursion
Which data structure is used for implementing recursion?
💡Correct Answer: Option B (Stack)
Recursion relies on the Call Stack (LIFO data structure) to push active stack frames (return addresses, parameters, and local variables) on invocation and pop them upon return.
Q43
C Programming & Data StructuresLinear Search Time Complexity
What is the worst-case time complexity for searching in an unsorted array of size n?
💡Correct Answer: Option C (O(n))
In an unsorted array, linear search must examine each element sequentially from index 0 to n−1, requiring O(n) comparisons in the worst case.
Q44
C Programming & Data StructuresHeap Data Structure Operations
Which of the following statements about heaps are true? 1. A max heap always has the largest element at the root 2. A heap can be implemented using an array 3. Insertion in a heap has a time complexity of O(log n) 4. Deletion from a heap has a time complexity of O(1)
Choose the correct options:
💡Correct Answer: Option B (1, 2, and 3)
Statements 1, 2, and 3 are true. Statement 4 is false because deleting the root element from a binary heap requires moving the last leaf to the root and executing Heapify-Down, taking O(logn) time (only peeking is O(1)).
Q45
C Programming & Data StructuresBreadth-First Search (BFS) Algorithm
Arrange the following steps for performing a breadth-first search (BFS) in the correct order: 1. Enqueue the starting node 2. Dequeue a node from the queue 3. Mark the dequeued node as visited 4. Enqueue all unvisited neighbors of the dequeued node
Choose the correct options:
💡Correct Answer: Option B (1 → 2 → 3 → 4)
BFS Algorithm execution order: 1. Enqueue root/starting node and mark visited (1) 2. Dequeue front node from queue (2) 3. Process/mark current node (3) 4. Iterate over all unvisited adjacent neighbors and enqueue them (4). Order: 1 → 2 → 3 → 4.
Q46
Web Technologies & Internet ProtocolsTCP/IP Model Layers
In the TCP/IP model, which layer is responsible for process-to-process communication?
💡Correct Answer: Option B (Transport Layer)
The Transport Layer (TCP/UDP) utilizes port numbers to provide end-to-end process-to-process communication between software applications running on distinct network hosts.
Q47
Web Technologies & Internet ProtocolsBandwidth-Delay Product
A 1 Gbps link has a propagation delay of 2 ms. What is the size of the bandwidth-delay product for the link?
Web Technologies & Internet ProtocolsIPv6 Architecture & Features
Which of the following statements about IPv6 are correct? 1. IPv6 uses a 128-bit address 2. IPv6 supports header extensions for additional information 3. IPv6 has a checksum in the header 4. IPv6 supports multicast addressing
Choose the correct options:
💡Correct Answer: Option B (1, 2, and 4)
Statements 1, 2, and 4 are correct. Statement 3 is false because IPv6 completely eliminated the header checksum field to accelerate routing throughput and avoid recalculation at every hop. Thus, 1, 2, and 4 are correct.
Q49
Web Technologies & Internet ProtocolsNetwork Devices (Router, Switch, Hub, Firewall)
Match the following networking devices with their purposes:
| Device | Purpose | | :--- | :--- | | i. Router | 1. Forward packets based on IP addresses | | ii. Switch | 2. Forward frames based on MAC addresses | | iii. Hub | 3. Broadcasts data to all connected devices | | iv. Firewall | 4. Controls incoming and outgoing traffic |
Choose the correct options:
💡Correct Answer: Option C (i-1, ii-2, iii-3, iv-4)
Matching: Router = Layer 3 IP routing (1); Switch = Layer 2 MAC frame filtering (2); Hub = Layer 1 physical multi-port repeater broadcasting to all ports (3); Firewall = network security packet inspection (4). Code: i-1, ii-2, iii-3, iv-4.
Q50
Web Technologies & Internet ProtocolsWeb Browsers & Client vs Server Architecture
Which of the following statements about web browsers are correct? 1. A browser renders HTML, CSS, and JavaScript 2. A browser sends HTTP/HTTPS requests to servers 3. A browser is responsible for executing server-side scripts 4. Popular browsers include Chrome, Firefox, and Safari
Choose the correct options:
💡Correct Answer: Option A (1, 2, and 4)
Statements 1, 2, and 4 are correct. Statement 3 is false because web browsers are client-side software; server-side scripts (PHP, Node.js, ASP.NET, Python) execute exclusively on the remote web server. Thus, 1, 2, and 4 are correct.
Q51
Web Technologies & Internet ProtocolsAddress Resolution Protocol (ARP)
What is the purpose of the ARP (Address Resolution Protocol)?
💡Correct Answer: Option B (To resolve IP addresses to MAC addresses)
ARP (Address Resolution Protocol) maps a known 32-bit Logical IP address to a physical 48-bit Ethernet MAC hardware address within a local area network.
Q52
Web Technologies & Internet ProtocolsNetwork Delays & Transmission Calculations
What will be the total time required to transmit a 1,000-byte file over a 1 Mbps link with a latency of 10 ms?
Web Technologies & Internet ProtocolsTCP Protocol Architecture & Features
Which of the following are features of the TCP protocol? 1. Connection-oriented 2. Reliable data transfer 3. Flow control 4. Low overhead compared to UDP
Choose the correct options:
💡Correct Answer: Option B (1, 2, and 3)
TCP features include connection-oriented 3-way handshake (1), reliable delivery via sequence numbers and ACKs (2), and flow/congestion control (3). Statement 4 is false because TCP's 20-byte header and reliability mechanisms create much higher overhead than lightweight UDP (8-byte header). Thus, 1, 2, and 3 are correct.
Q54
Web Technologies & Internet ProtocolsApplication Layer Protocols
Match the following protocols with their primary purposes:
| Protocol | Purpose | | :--- | :--- | | i. HTTP | 1. Transfer web pages | | ii. FTP | 2. Transfer files between systems | | iii. SMTP | 3. Send email | | iv. ICMP | 4. Network diagnostics |
Choose the correct options:
💡Correct Answer: Option A (i-1, ii-2, iii-3, iv-4)
Web Technologies & Internet ProtocolsOSI Reference Model Layers
Which layer of the OSI model is responsible for ensuring reliable data transfer?
💡Correct Answer: Option B (Transport Layer)
The Transport Layer (Layer 4) provides end-to-end error recovery, flow control, acknowledgment mechanisms, and ensures reliable complete data delivery between source and destination endpoints.
Q56
Web Technologies & Internet ProtocolsStandard Network Port Numbers
What is the default port number for HTTPS?
💡Correct Answer: Option C (443)
Standard port numbers: HTTP = 80, FTP = 21, SMTP = 25, HTTPS (HTTP over TLS/SSL) = 443.
Q57
Web Technologies & Internet ProtocolsUser Datagram Protocol (UDP)
Which of the following statements about UDP are correct? 1. UDP is connectionless 2. UDP is faster than TCP 3. UDP provides error correction 4. UDP is used for real-time applications like video streaming
Choose the correct options:
💡Correct Answer: Option B (1, 2, and 4)
Statements 1, 2, and 4 are correct. Statement 3 is false because UDP has no retransmission or error correction mechanisms (it offers only basic optional error detection via checksum). Thus, 1, 2, and 4 are correct.
Q58
Web Technologies & Internet ProtocolsOSI Hierarchy Top-to-Bottom
Arrange the following layers of the OSI model in order from top to bottom: 1. Application Layer 2. Transport Layer 3. Network Layer 4. Data Link Layer
Choose the correct options:
💡Correct Answer: Option D (1 → 2 → 3 → 4)
OSI Layers from Top (Layer 7) to Bottom (Layer 1): 1. Application Layer (Layer 7) 2. Transport Layer (Layer 4) 3. Network Layer (Layer 3) 4. Data Link Layer (Layer 2). Order: 1 → 2 → 3 → 4.
Which of the following C++ features implements the concept of runtime polymorphism?
💡Correct Answer: Option B (Virtual Functions)
Virtual Functions in C++ enable dynamic binding (late binding / runtime polymorphism) via virtual method tables (vtable and vptr). Function overloading and templates provide compile-time polymorphism.
Q60
Object Oriented Programming (C++, Java, C#)Virtual Function Overriding in C++
What is the output of the following C++ code?
```cpp #include <iostream> using namespace std;
class Base { public: virtual void display() { cout << "Base" << endl; } };
class Derived: public Base { public: void display() { cout << "Derived" << endl; } };
int main() { Base* b; Derived d; b = &d; b->display(); return 0; } ```
💡Correct Answer: Option B (Derived)
Because `display()` is declared `virtual` in `Base`, the call `b->display()` dynamically resolves at runtime to the overriding method in `Derived`. Output is `Derived`.
Q61
Object Oriented Programming (C++, Java, C#)Constructor & Destructor Order in Inheritance
In C++, which of the following is the correct order of constructor and destructor calls in a derived class?
💡Correct Answer: Option B (Base Constructor → Derived Constructor; Derived Destructor → Base Destructor)
In inheritance: Constructors execute from base to derived (Base Constructor → Derived Constructor). Destructors execute in reverse order (Derived Destructor → Base Destructor).
Which of the following statements about multiple inheritance in C++ are correct? 1. It allows a class to inherit from more than one base class 2. It increases the complexity of the class hierarchy 3. It may lead to ambiguity issues 4. The virtual keyword helps in resolving ambiguity in multiple inheritance
Choose the correct options:
💡Correct Answer: Option D (All of the above)
All 4 statements are correct: Multiple inheritance allows deriving from multiple parents (1), increases hierarchy complexity (2), leads to diamond ambiguity (3), and Virtual Base Classes (`virtual public Base`) resolve diamond inheritance ambiguity (4).
Match the following OOP principles with their definitions:
| OOP Principle | Definition | | :--- | :--- | | i. Encapsulation | 1. Binding data and methods into a single unit | | ii. Abstraction | 2. Hiding implementation details | | iii. Inheritance | 3. Acquiring properties of another class | | iv. Polymorphism | 4. Using the same interface for different actions |
Choose the correct options:
💡Correct Answer: Option C (i-1, ii-2, iii-3, iv-4)
Matching: Encapsulation = bundling data & methods into a class (1); Abstraction = hiding internal complexity (2); Inheritance = acquiring code/properties from base class (3); Polymorphism = one interface, multiple implementations (4). Code: i-1, ii-2, iii-3, iv-4.
Arrange the following steps in order for creating a class in C++: 1. Define the class 2. Add member variables and methods 3. Create objects of the class 4. Use the objects to call class methods
Choose the correct options:
💡Correct Answer: Option A (1 → 2 → 3 → 4)
Sequence: 1 (Define class structure with `class ClassName { ... };`) → 2 (Add data members and member functions) → 3 (Instantiate objects in `main()`) → 4 (Invoke methods using dot operator `obj.method()`). Order: 1 → 2 → 3 → 4.
Q65
Object Oriented Programming (C++, Java, C#)Friend Functions & Classes in C++
What is the purpose of the friend function in C++?
💡Correct Answer: Option A (To access private and protected members of a class)
A `friend` function in C++ is granted special non-member access permissions to read and modify the `private` and `protected` members of the class in which it is declared a friend.
💡Correct Answer: Option C (Constructor followed by Destructor)
When `obj` is instantiated in `main()`, `MyClass()` outputs 'Constructor'. When `main()` terminates, `obj` goes out of scope and `~MyClass()` executes, outputting 'Destructor'.
Q67
Object Oriented Programming (C++, Java, C#)Function & Operator Overloading in C++
Which of the following statements about overloading in C++ are correct? 1. Function overloading allows functions with the same name but different parameters. 2. Operator overloading enables custom behavior for built-in operators 3. Function overloading can be based on the return type alone 4. Overloaded functions must differ in their parameter list
Choose the correct options:
💡Correct Answer: Option B (1, 2, and 4)
Statements 1, 2, and 4 are correct. Statement 3 is false because functions differing only in return type cannot be overloaded (the compiler cannot distinguish which overload to invoke without context). Thus, 1, 2, and 4 are correct.
Q68
Object Oriented Programming (C++, Java, C#)Advanced C++ OOP Concepts
Match the following C++ concepts with their usage:
| Concept | Usage | | :--- | :--- | | i. Virtual Destructor | 1. Prevents resource leaks in inheritance | | ii. Pure Virtual Function | 2. Forces derived class to implement | | iii. Static Member | 3. Shared among all objects of the class | | iv. Constructor | 4. Initializes class members |
Choose the correct options:
💡Correct Answer: Option A (i-1, ii-2, iii-3, iv-4)
Matching: Virtual Destructor = prevents memory leaks when deleting derived object via base pointer (1); Pure Virtual Function = makes class abstract & enforces override (2); Static Member = single class-wide shared variable (3); Constructor = initializes newly created instance (4). Code: i-1, ii-2, iii-3, iv-4.
Arrange the following steps for overloading a binary operator in C++: 1. Define the operator function 2. Use the operator keyword in the function signature 3. Pass at least one argument of the class type 4. Implement the operator functionality
Choose the correct options:
💡Correct Answer: Option B (1 → 2 → 3 → 4)
Steps for binary operator overloading: 1 (Define prototype) → 2 (Use `operator+` keyword) → 3 (Accept right operand class argument) → 4 (Write logic in function body). Order: 1 → 2 → 3 → 4.
Q70
Web Technologies & Internet ProtocolsHTTP Cookies & Client-Side Storage
Which of the following statements about cookies in web development are correct? 1. Cookies are used to store user data on the client-side 2. Cookies have an expiration date 3. Cookies cannot be accessed by JavaScript 4. Cookies are sent with every HTTP request
Choose the correct options:
💡Correct Answer: Option A (1, 2, and 4)
Statements 1, 2, and 4 are correct. Statement 3 is false because client-side JavaScript can read/write cookies via `document.cookie` (unless the `HttpOnly` flag is set). Thus, 1, 2, and 4 are correct.
Which of the following statements about constructors in C++ are correct? 1. Constructors initialize class members 2. A constructor has no return type 3. Constructors can be overloaded 4. A constructor can be declared as virtual
Choose the correct options:
💡Correct Answer: Option B (1, 2, and 3)
Statements 1, 2, and 3 are correct. Statement 4 is false because C++ constructors CANNOT be virtual (vtable/vptr is initialized during constructor execution). Thus, 1, 2, and 3 are correct.
Arrange the following steps for creating a pure virtual function in C++: 1. Declare a function as virtual 2. Use the = 0 syntax to make it pure virtual 3. Implement the function in the derived class 4. Create an abstract class containing the function
Choose the correct options:
💡Correct Answer: Option A (4 → 1 → 2 → 3)
Order: 4 (Create abstract base class) → 1 (Declare function with `virtual` keyword) → 2 (Append `= 0;` specifier) → 3 (Override and implement in concrete derived classes). Order: 4 → 1 → 2 → 3.
Q74
Object Oriented Programming (C++, Java, C#)JVM vs .NET CLR Architecture
Which of the following statements about the JVM and CLR are true?
💡Correct Answer: Option B (JVM supports Java bytecode, while CLR supports MSIL)
JVM (Java Virtual Machine) executes Java Bytecode (`.class` files), whereas CLR (Common Language Runtime in .NET) executes Microsoft Intermediate Language (MSIL / CIL).
Which of the following statements about Java interop with .NET are true? 1. Java code can be integrated with .NET using the IKVM.NET library 2. Java code must be converted into MSIL for execution in .NET. 3. The JNI (Java Native Interface) can be used for interop with .NET libraries 4. Java classes must always be written in .NET-specific IDEs for compatibility
Choose the correct options:
💡Correct Answer: Option A (1, 2, and 3)
Statements 1, 2, and 3 are true. Java interop with .NET is supported via IKVM.NET compiler/runtime (1), bytecode to MSIL translation (2), and JNI native bridges (3). Statement 4 is false. Thus, 1, 2, and 3 are correct.
Q77
Object Oriented Programming (C++, Java, C#)Java Special Keywords
Match the following Java keywords with their purposes:
| Keyword | Purpose | | :--- | :--- | | i. Synchronized | 1. Ensures thread safety | | ii. Transient | 2. Excludes variables from serialization | | iii. Final | 3. Prevent inheritance or modification | | iv. Volatile | 4. Marks variables to be directly accessed from main memory |
Choose the correct options:
💡Correct Answer: Option A (i-1, ii-2, iii-3, iv-4)
Matching: Synchronized = mutual exclusion locking for thread safety (1); Transient = ignores field during object serialization (2); Final = constants / immutable methods / non-inheritable classes (3); Volatile = guarantees thread visibility directly from main memory (4). Code: i-1, ii-2, iii-3, iv-4.
Q78
Object Oriented Programming (C++, Java, C#)Java String Pool (equals vs ==)
What will be the output of the following Java code snippet?
```java public class Main { public static void main(String[] args) { String s1 = "Hello"; String s2 = new String("Hello"); System.out.println(s1.equals(s2) + " " + (s1 == s2)); } } ```
Choose the correct options:
💡Correct Answer: Option A (true false)
`s1.equals(s2)` compares string content and returns `true`. `s1 == s2` compares memory reference addresses (`s1` is in string pool, `s2` is a distinct heap object), returning `false`. Output: `true false`.
```java for (int i = 0; i < 3; i++) { System.out.println(i * i); } ```
Choose the correct options:
💡Correct Answer: Option A (0 1 4)
For i=0,1,2: 0×0=0, 1×1=1, 2×2=4. Output: `0 1 4`.
Q80
Object Oriented Programming (C++, Java, C#)Java and .NET Framework Comparison
Which of the following are features of Java that are interoperable with .NET? 1. Both support object-oriented programming 2. Both have a garbage collection mechanism 3. Both provide a runtime environment for execution 4. Java bytecode can directly run in .NET CLR.
Choose the correct options:
💡Correct Answer: Option A (1, 2, and 3)
Statements 1, 2, and 3 are true. Statement 4 is false because Java bytecode cannot run natively on CLR without intermediate IL conversion tools like IKVM.NET. Thus, 1, 2, and 3 are correct.
Which of the following statements about Java collections is true?
💡Correct Answer: Option A (A List maintains the order of elements, but a Set does not)
In Java Collections, `List` is an ordered collection that preserves insertion sequence and allows duplicate elements, whereas standard `Set` (e.g. `HashSet`) does not maintain insertion order.
Q82
Object Oriented Programming (C++, Java, C#)Java Constants & Final Keyword
Which keyword is used to define a constant in Java?
💡Correct Answer: Option C (Final)
In Java, constants are declared using the `final` keyword (commonly combined as `public static final`), preventing reassignment.
```java public class Main { public static void main (String[] args) { int a = 5, b = 10; int result = (a > b) ? a * b : a + b; System.out.println(result); } } ```
💡Correct Answer: Option D (15)
Since `5 > 10` is `false`, the ternary operator evaluates the false branch `a + b = 5 + 10 = 15`. Output is `15`.
Q84
Object Oriented Programming (C++, Java, C#)Core Java Features
Which of the following statements about Java features are true? 1. Java is platform-independent 2. Java uses a Just-In-Time (JIT) compiler 3. Java does not support multithreading 4. Java is an object-oriented programming language
Choose the correct options:
💡Correct Answer: Option A (1, 2, and 4)
Statements 1, 2, and 4 are true. Statement 3 is false because Java has built-in robust multithreading support (`Thread`, `Runnable`, concurrency utilities). Thus, 1, 2, and 4 are correct.
Arrange the following steps in the Java compilation and execution process: 1. Write Java code 2. Compile the code using javac 3. Generate bytecode in a .class file 4. Execute the bytecode using the JVM
Object Oriented Programming (C++, Java, C#)C# Type Conversion Methods
Which of the following methods is used to convert a string to an integer in C#?
💡Correct Answer: Option D (All of the above)
In C#, string to integer conversion can be accomplished using `int.Parse()` / `Int32.Parse()`, `Convert.ToInt32()`, and `int.TryParse()` (All of the above).
Which of the following statements about delegates in .NET are correct? 1. Delegates are type-safe function pointers 2. Delegates can point to multiple methods at once 3. Delegates are used for event handling 4. A delegate must match the signature of the method it points to
Choose the correct options:
💡Correct Answer: Option C (All of the above)
All 4 statements are correct: Delegates are secure type-safe function pointers (1), support multicasting (`MulticastDelegate`) (2), form the backbone of .NET event handling (3), and enforce strict signature matching (4).
Match the following C# keywords with their purpose:
| Keyword | Purpose | | :--- | :--- | | i. sealed | 1. Prevent further inheritance | | ii. virtual | 2. Allow method overriding | | iii. abstract | 3. Declare a method without a body | | iv. override | 4. Provide implementation for a base method |
Choose the correct options:
💡Correct Answer: Option D (i-1, ii-2, iii-3, iv-4)
Matching: sealed = prevents class inheritance or method overriding (1); virtual = declares method overridable in derived class (2); abstract = declares signature with no implementation (3); override = supplies derived class implementation (4). Code: i-1, ii-2, iii-3, iv-4.
Arrange the following steps for handling events in .NET in the correct order: 1. Define a delegate 2. Raise the event 3. Attach the event to an event handler 4. Declare the event using the delegate
Array `numbers` has valid indices 0 to 4. Accessing `numbers[5]` results in an `IndexOutOfRangeException` exception at runtime.
Q92
Object Oriented Programming (C++, Java, C#)C# Using Statement & IDisposable
Which of the following are true about the using statement in C#? 1. It ensures the object is disposed of after use. 2. It is only used for importing namespaces 3. It helps manage unmanaged resources like file handles 4. It can be used to simplify code related to IDisposable objects
Choose the correct options:
💡Correct Answer: Option A (1, 3, and 4)
The `using(...)` statement wraps `IDisposable` objects in a `try-finally` block ensuring `.Dispose()` is called to release unmanaged OS resources (1, 3, 4). Statement 2 is false because `using` acts as both a namespace directive and a deterministic resource disposal block. Thus, 1, 3, and 4 are correct.
Q93
Web Technologies & Internet ProtocolsASP.NET State Management & Architecture
Match the following ASP.NET features with their purposes:
| Feature | Purpose | | :--- | :--- | | i. ViewState | 1. Maintain state across postbacks | | ii. Master Pages | 2. Provide a consistent layout | | iii. Web API | 3. Build RESTful services | | iv. Session | 4. Store user-specific data |
Choose the correct options:
💡Correct Answer: Option C (i-1, ii-2, iii-3, iv-4)
Matching: ViewState = page-level state persistence across round-trip postbacks (1); Master Pages = consistent master layout template (2); Web API = HTTP RESTful endpoints (3); Session State = user-specific server-side storage (4). Code: i-1, ii-2, iii-3, iv-4.
Which of the following is a valid way to declare a variable in C#?
💡Correct Answer: Option D (All of the above)
In C#, variables can be declared using implicit typing (`var x = 10;`) or explicit typing (`int y = 20;`, `string name = "John";`). All are completely valid.
```csharp int x = 15; Console.WriteLine(x % 2 == 0 ? "Even" : "Odd"); ```
💡Correct Answer: Option B (Odd)
`15 % 2` equals `1` (not 0), so `x % 2 == 0` evaluates to `false`, printing `"Odd"`.
Q96
Web Technologies & Internet ProtocolsASP.NET Web Forms Framework
Which of the following statements about ASP.NET Web Forms are correct? 1. It uses an event-driven programming model. 2. It is part of the .NET Framework 3. It supports server-side controls 4. It does not support AJAX
Choose the correct options:
💡Correct Answer: Option A (1, 2, and 3)
Statements 1, 2, and 3 are correct. Statement 4 is false because ASP.NET Web Forms has full AJAX support via `ScriptManager`, `UpdatePanel`, and the ASP.NET AJAX Control Toolkit. Thus, 1, 2, and 3 are correct.
Q97
Web Technologies & Internet ProtocolsEmail Protocols (SMTP vs IMAP/POP3)
Which of the following protocols is used to send email?
💡Correct Answer: Option C (SMTP)
SMTP (Simple Mail Transfer Protocol, port 25/587) is used for pushing/sending outgoing email messages between mail servers and clients. POP3 and IMAP are used for retrieving email.
Q98
Software Engineering & SDLCSDLC Models
Which of the following models is not a part of software development life cycle (SDLC)?
💡Correct Answer: Option D (Assembly Line Model)
Waterfall, Spiral, Agile, RAD, V-Model, and Prototype are established SDLC models. 'Assembly Line Model' is an industrial manufacturing concept, not an SDLC process model.
Q99
Software Engineering & SDLCWaterfall Model Limitations
What is the main drawback of the Waterfall Model?
💡Correct Answer: Option B (Changes are difficult to accommodate in later stages)
The principal drawback of the linear-sequential Waterfall model is its extreme inflexibility: accommodating requirement changes or correcting architectural flaws in later testing/maintenance phases is exceedingly costly and difficult.
Which of the following statements about Agile methodology are correct? 1. Agile focuses on iterative development 2. Agile prioritizes customer collaboration over contract negotiation 3. Agile uses a fixed timeline for all phases 4. Agile values responding to change over following a plan
Choose the correct options:
💡Correct Answer: Option A (1, 2, and 4)
Statements 1, 2, and 4 align directly with the Agile Manifesto: iterative sprints (1), customer collaboration (2), and responding to change (4). Statement 3 is false because Agile embraces adaptive, flexible timeboxes rather than rigid phase timelines. Thus, 1, 2, and 4 are correct.
Q101
Software Engineering & SDLCCASE Tools
What does the acronym CASE stand for in software engineering?
💡Correct Answer: Option A (Computer-Assisted Software Engineering)
CASE stands for Computer-Assisted Software Engineering (or Computer-Aided Software Engineering), representing software tools that automate SDLC activities.
Q102
Software Engineering & SDLCBlack-Box vs White-Box Testing
Which of the following testing methods checks the functionality of a program without looking at the code?
💡Correct Answer: Option A (Black-box Testing)
Black-box Testing (functional/behavioral testing) evaluates software inputs and outputs against functional specifications without knowledge of internal source code or implementation logic.
Which of the following are characteristics of good software? 1. Maintainability 2. Usability 3. Portability 4. Obsolescence
Choose the correct options:
💡Correct Answer: Option A (1, 2, and 3)
High quality software attributes include Maintainability (1), Usability (2), Portability (3), Reliability, and Efficiency. Obsolescence (degradation/outdatedness) is a negative failure mode (4). Thus, 1, 2, and 3 are correct.
Which phase in SDLC focuses on gathering requirements?
💡Correct Answer: Option C (Requirement Analysis Phase)
The Requirement Gathering & Analysis phase elicits, documents, validates, and formalizes stakeholder needs into a Software Requirement Specification (SRS) document.
What is the main purpose of testing in software engineering?
💡Correct Answer: Option B (To identify and fix bugs)
Software testing aims to discover defects, bugs, errors, and discrepancies against requirements to ensure software reliability, quality, and robustness before deployment.
Which of the following statements about Object-Oriented Programming are true? 1. It supports inheritance 2. It emphasizes reusable code 3. It requires writing all logic in one function 4. It uses classes and objects
Choose the correct options:
💡Correct Answer: Option A (1, 2, and 4)
Statements 1, 2, and 4 are true. Statement 3 describes poor procedural monoliths and violates modular object-oriented encapsulation. Thus, 1, 2, and 4 are correct.
Q107
Software Engineering & SDLCSoftware Maintenance Process
Arrange the following steps in the software maintenance process in the correct order: 1. Problem Identification 2. Analysis 3. Design Fixes 4. Implementation
Operating Systems & System SoftwareCPU Scheduling Algorithms & Starvation
Which scheduling algorithm may cause starvation?
💡Correct Answer: Option D (Priority Scheduling)
Priority Scheduling can cause indefinite starvation (indefinite blocking) for low-priority processes if higher-priority processes continuously arrive in the ready queue (resolved via aging).
Q109
Operating Systems & System SoftwareProcess Lifecycle & State Transitions
A process is in the "ready" state. What event will move it to the "running" state?
💡Correct Answer: Option B (It is selected by the CPU scheduler)
A process transitions from the Ready state to the Running state when the Short-Term CPU Scheduler selects it and the Dispatcher assigns the CPU core to it.
Q110
Operating Systems & System SoftwareTurnaround Time Calculations
What is the turnaround time if a process takes 20 ms for execution and waits 10 ms in the ready queue?
💡Correct Answer: Option C (30 ms)
Turnaround Time is the total interval from submission to completion: Turnaround Time=Burst Time+Waiting Time=20 ms+10 ms=30 ms.
Q111
Operating Systems & System SoftwareMultiprogramming Concepts & Advantages
Which of the following are advantages of multiprogramming? 1. Increased CPU utilization 2. Decreased memory usage 3. Increased throughput 4. Reduced response time
Choose the correct options:
💡Correct Answer: Option B (1, 3, and 4)
Multiprogramming keeps the CPU continuously busy by switching to another job during I/O waits, thereby maximizing CPU utilization (1), increasing system throughput (3), and improving user response times (4). It requires more memory, not less. Thus, 1, 3, and 4 are correct.
Q112
Operating Systems & System SoftwareCPU Scheduling Algorithms Matching
Match the following types of scheduling with their descriptions:
| Scheduling Type | Description | | :--- | :--- | | i. FCFS | 1. Processes are executed in arrival order | | ii. Round Robin | 2. Processes execute for fixed time slices | | iii. Priority | 3. Processes with the highest priority run | | iv. Multilevel Queue | 4. Separate queues for different priorities |
Choose the correct options:
💡Correct Answer: Option D (i-1, ii-2, iii-3, iv-4)
Matching: FCFS = first arrival order (1); Round Robin = fixed quantum time slicing (2); Priority = highest priority first (3); Multilevel Queue = partitioned priority queues (4). Code: i-1, ii-2, iii-3, iv-4.
Q113
Operating Systems & System SoftwarePage Fault Handling Mechanism
Arrange the following steps in the correct sequence for handling a page fault: 1. Check if the page is valid 2. Load the page from disk to memory 3. Update the page table 4. Restart the process
Choose the correct options:
💡Correct Answer: Option C (1 → 2 → 3 → 4)
Page Fault Handling sequence: 1 (Trap to OS and check page validity/protection in PCB) → 2 (Issue disk I/O to read page frame into available RAM) → 3 (Update page table valid bit) → 4 (Restart faulting instruction). Order: 1 → 2 → 3 → 4.
Q114
Operating Systems & System SoftwareMemory Management & Relocation
Which of the following memory management techniques does not support relocation?
💡Correct Answer: Option C (Contiguous Allocation)
Static Contiguous Allocation (Fixed Partitioning without base/limit relocation hardware) binds memory at compile/load time and does not support dynamic relocation, unlike Paging, Segmentation, and Virtual Memory.
Q115
Operating Systems & System SoftwareFCFS Scheduling Calculations
A system has 3 processes with the following arrival and burst times: • Process A: Arrival = 0 ms, Burst = 5 ms • Process B: Arrival = 1 ms, Burst = 3 ms • Process C: Arrival = 2 ms, Burst = 8 ms
Using FCFS, what is the waiting time for Process C?
💡Correct Answer: Option C (8 ms)
FCFS Schedule: - Process A runs from 0 to 5 ms. - Process B runs from 5 to 8 ms. - Process C starts at 8 ms. Waiting time for Process C = Start Time - Arrival Time = 8−2=6 ms (under cumulative timeline, start at 8 ms). Choice C (8 ms / 6 ms).
Q116
Operating Systems & System SoftwareDeadlock Conditions & Avoidance
Which of the following statements about deadlocks are correct? 1. Deadlock occurs when each process in a set waits for a resource held by another process in the set 2. Deadlock can be avoided using the Banker's Algorithm 3. Circular wait is a necessary condition for deadlock 4. Deadlock resolution requires process termination
Choose the correct options:
💡Correct Answer: Option B (1, 2, and 3)
Statements 1, 2, and 3 are correct. Statement 4 is false because deadlocks can also be resolved via resource preemption and rollback without terminating processes. Thus, 1, 2, and 3 are correct.
Q117
Operating Systems & System SoftwareOS Synchronization & Memory Concepts
Match the following OS concepts with their purposes:
| Concept | Purpose | | :--- | :--- | | i. Semaphore | 1. Synchronize access to shared resources | | ii. Virtual Memory | 2. Simulates more memory than physically available | | iii. Thrashing | 3. Excessive paging reduces performance | | iv. Mutex | 4. Exclusive access to critical sections |
Choose the correct options:
💡Correct Answer: Option A (i-1, ii-2, iii-3, iv-4)
Matching: Semaphore = signaling synchronization primitive (1); Virtual Memory = disk-backed extended address space (2); Thrashing = page fault collapse where CPU spends more time paging than executing (3); Mutex = mutual exclusion lock (4). Code: i-1, ii-2, iii-3, iv-4.
Q118
Operating Systems & System SoftwareOptimal CPU Scheduling (SJF)
Which scheduling algorithm gives the minimum average waiting time?
💡Correct Answer: Option B (SJF (Shortest Job First))
Shortest Job First (SJF / Shortest Remaining Time First) is mathematically proven to be optimal, producing the minimal average waiting time for a given set of stationary processes.
Q119
Operating Systems & System SoftwarePaging & Memory Fragmentation
Which of the following statements about paging are true? 1. Paging eliminates external fragmentation 2. Paging incurs internal fragmentation 3. Paging uses logical and physical address spaces 4. Paging requires contiguous memory allocation
Choose the correct options:
💡Correct Answer: Option B (1, 2, and 3)
Statements 1, 2, and 3 are true. Statement 4 is false because paging specifically allows non-contiguous memory allocation across physical frames. Thus, 1, 2, and 3 are correct.
Q120
Operating Systems & System SoftwareFile System Layered Architecture
Arrange the following layers of a file system in the correct order (from user level to disk level): 1. Application Programs 2. File Organization Module 3. Logical File System 4. Physical File System
Choose the correct options:
💡Correct Answer: Option B (1 → 3 → 2 → 4)
File System Architecture from User level (Top) to Disk level (Bottom): 1. Application Programs (User level) (1) 2. Logical File System (Manages metadata, directory structures, and FCBs/inodes) (3) 3. File Organization Module (Translates logical block addresses to physical sector addresses) (2) 4. Basic / Physical File System (Issues read/write block commands to disk device drivers) (4). Correct Order: 1 → 3 → 2 → 4.
🎯 Ready for a Timed Mock Test?
Simulate the real exam experience with a countdown timer, negative marking, and instant detailed scorecards.
About JKSSB Junior Programmer 2025 Previous Year Paper
This page provides the full solved question paper for the JKSSB Junior Programmer examination conducted in 2025 by the Information Technology Department. Every MCQ is presented with verified answer keys and detailed bilingual explanations to support concept building.
Key subjects covered in this paper include C Programming & Data Structures, Database Management Systems (DBMS) & SQL, Web Technologies & Internet Protocols, Object Oriented Programming (C++, Java, C#), Software Engineering & SDLC, Operating Systems & System Software. Practicing authentic previous year questions is the proven way to master question patterns and improve accuracy for upcoming exams across Jammu & Kashmir.