कम्प्युटर / सूचना प्रविधि कम्प्युटर अधिकृत (सातौँ तह) – प्राविधिक पत्र
कम्प्युटर / सूचना प्रविधि – कम्प्युटर अधिकृत (सातौँ तह)
Computer Officer – 7th Level · Computer & IT Posts
२,५७७ प्रश्न उपलब्ध। मोड छान्नुहोस्:
प्राविधिक पत्र: प्रश्न र उत्तर
सही लागेको विकल्पमा थिच्नुहोस्। सही भए हरियो, गलत भए रातो देखिन्छ; ५ सेकेन्डपछि सही उत्तर र व्याख्या देखिन्छ।
सही: ० / ०
-
What is printed by the C code: char s[] = "Hello"; s[0] = s[4]; printf("%s", s); ?
सही उत्तर: ग) oello
s[4] is 'o', which overwrites s[0] ('H'), so the array now holds "oello".
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
What is printed by the C code: int i = 10; while (i >= 1) i = i / 2; printf("%d", i); ?
सही उत्तर: क) 0
i takes the values 10, 5, 2, 1 and then 0; the loop stops when i becomes 0, which is printed.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
Keeping C operator precedence in mind, which number does printf("%d", 1 << 3 + 1); display?
सही उत्तर: ग) 16
Addition has higher precedence than shift, so it is 1 << 4 = 16.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
What is printed by the C code: int x = 6; printf("%d", x & 3 | 8); ?
सही उत्तर: ग) 10
& has higher precedence than |: 6 & 3 = 2 (110 & 011 = 010), then 2 | 8 = 10.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
Mixing integer division and remainder, which value appears on the screen when a C program executes printf("%d", 10 / 3 * 3 + 10 % 3 * 2); ?
सही उत्तर: ख) 11
10 / 3 * 3 = 3 * 3 = 9 (integer division) and 10 % 3 * 2 = 1 * 2 = 2, so the result is 9 + 2 = 11.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
For large n, which function grows faster?
सही उत्तर: घ) n! (n factorial)
n! grows faster than any exponential c^n with constant c; for example 20! is about 2.4 x 10^18 while 2^20 is about 10^6.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
Kruskal's minimum spanning tree algorithm uses which data structure to check whether adding an edge would form a cycle?
सही उत्तर: ख) Disjoint-set (union-find)
Union-find tracks which vertices are already connected; an edge whose ends are in the same set would create a cycle.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
Which tree data structure is designed for fast prefix searches on strings, as used in autocomplete?
सही उत्तर: ग) Trie
In a trie each edge stands for a character, so all words sharing a prefix lie under one node.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
Level-order traversal of a binary tree (visiting nodes level by level) is implemented using a:
सही उत्तर: क) Queue
Nodes are enqueued as they are discovered and processed in FIFO order, giving a breadth-first visit.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
When deleting a node that has two children from a binary search tree, the node is commonly replaced by its:
सही उत्तर: ख) Inorder successor (smallest key in its right subtree)
Using the inorder successor (or inorder predecessor) keeps the BST ordering property intact.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
यी अभ्यास प्रश्न हुन्, आधिकारिक प्रश्न होइनन्। पाठ्यक्रम, विज्ञापन र नतिजाका लागि सम्बन्धित निकायको आधिकारिक वेबसाइट हेर्नुहोस्। उत्तरमा गल्ती भेटे प्रश्नमुनिको "टिप्पणी / गल्ती रिपोर्ट" मा लेख्नुहोस्।
नमस्ते! पाठ्यक्रम, सामान्य ज्ञान, भाषा परीक्षा वा कुनै प्रश्नको उत्तर बुझ्न सोध्नुहोस्।
AI ले गल्ती गर्न सक्छ। महत्वपूर्ण कुरा आधिकारिक स्रोतमा जाँच्नुहोस्।