कम्प्युटर / सूचना प्रविधि कम्प्युटर अधिकृत (सातौँ तह) – प्राविधिक पत्र
कम्प्युटर / सूचना प्रविधि – कम्प्युटर अधिकृत (सातौँ तह)
Computer Officer – 7th Level · Computer & IT Posts
२,५७७ प्रश्न उपलब्ध। मोड छान्नुहोस्:
प्राविधिक पत्र: प्रश्न र उत्तर
सही लागेको विकल्पमा थिच्नुहोस्। सही भए हरियो, गलत भए रातो देखिन्छ; ५ सेकेन्डपछि सही उत्तर र व्याख्या देखिन्छ।
सही: ० / ०
-
In C++, the 'diamond problem' of multiple inheritance (duplicate copies of a common base class) is solved by using:
सही उत्तर: क) virtual base classes (virtual inheritance)
Declaring the common base as virtual ensures only one shared copy of it exists in the most-derived object.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
When several derived classes inherit from a single base class, the inheritance is called:
सही उत्तर: ख) hierarchical inheritance
One base class with many child classes forms a hierarchy, i.e. hierarchical inheritance.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
Class C inherits from class B, and class B inherits from class A. This type of inheritance is called:
सही उत्तर: घ) multilevel inheritance
A chain of derivation A -> B -> C is multilevel inheritance.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
In object-oriented programming, a class is best described as:
सही उत्तर: क) a blueprint or template from which objects are created
A class defines the data and methods; objects are concrete instances created from it.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
In OOP, showing only the essential features of an object while hiding unnecessary implementation details is called:
सही उत्तर: क) abstraction
Abstraction exposes what an object does through a simple interface and hides how it does it.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
In C, the expression *p++ (where p is a pointer):
सही उत्तर: ग) yields the value p points to, then increments the pointer p
Postfix ++ binds tighter than *, so p++ is applied to the pointer; the old address is dereferenced and p then moves to the next element.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
What is printed by: int i; for (i = 0; i < 5; i++) { if (i == 3) continue; printf("%d", i); }
सही उत्तर: घ) 0124
When i is 3, continue skips the printf; all other values 0, 1, 2, 4 are printed.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
A recursive function that has no reachable base case will usually end in:
सही उत्तर: ग) a stack overflow
Each call adds a stack frame; without a base case, calls never stop until the call stack is exhausted.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
What is printed by: char *s = "Lok Sewa"; printf("%c", *(s + 4));
सही उत्तर: घ) S
Indexing from 0: L(0) o(1) k(2) space(3) S(4), so *(s + 4) is 'S'.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
For a C function call swap(&x, &y) that exchanges two int variables, the function's parameters should be declared as:
सही उत्तर: घ) pointers to int (int *a, int *b)
Addresses are passed, so the parameters must be pointers to int; C has no reference parameters like int &a.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
यी अभ्यास प्रश्न हुन्, आधिकारिक प्रश्न होइनन्। पाठ्यक्रम, विज्ञापन र नतिजाका लागि सम्बन्धित निकायको आधिकारिक वेबसाइट हेर्नुहोस्। उत्तरमा गल्ती भेटे प्रश्नमुनिको "टिप्पणी / गल्ती रिपोर्ट" मा लेख्नुहोस्।
नमस्ते! पाठ्यक्रम, सामान्य ज्ञान, भाषा परीक्षा वा कुनै प्रश्नको उत्तर बुझ्न सोध्नुहोस्।
AI ले गल्ती गर्न सक्छ। महत्वपूर्ण कुरा आधिकारिक स्रोतमा जाँच्नुहोस्।