कम्प्युटर / सूचना प्रविधि कम्प्युटर अपरेटर (पाँचौँ तह) र सहायक – प्राविधिक पत्र
कम्प्युटर / सूचना प्रविधि – कम्प्युटर अपरेटर (पाँचौँ तह) र सहायक
Computer Operator & Assistant · Computer & IT Posts
२,५७७ प्रश्न उपलब्ध। मोड छान्नुहोस्:
प्राविधिक पत्र: प्रश्न र उत्तर
सही लागेको विकल्पमा थिच्नुहोस्। सही भए हरियो, गलत भए रातो देखिन्छ; ५ सेकेन्डपछि सही उत्तर र व्याख्या देखिन्छ।
सही: ० / ०
-
In Python, def make(k): return lambda x: x * k. After double = make(2), what does print(double(double(5))) display?
सही उत्तर: क) 20
The returned function remembers k = 2 (a closure), so double(5) = 10 and double(10) = 20.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
In Python, def f(n): return [] if n == 0 else f(n - 1) + [n]. What does print(f(3)) display?
सही उत्तर: ख) [1, 2, 3]
f(3) = f(2) + [3] = (f(1) + [2]) + [3] = [1] + [2] + [3] = [1, 2, 3].
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
A list is unpacked into print() with the star operator: print(*[1, 2, 3], sep=''). What is displayed?
सही उत्तर: ग) 123
The * unpacks the list into three separate arguments, printed with an empty separator.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
What is the output of the Python code: print(min('banana'), max('banana')) ?
सही उत्तर: क) a n
Characters are compared by code value: the smallest letter in "banana" is a and the largest is n.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
What is the output of the Python code: d = {'x': 3, 'y': 1, 'z': 2}; print(sorted(d, key=d.get)) ?
सही उत्तर: ग) ['y', 'z', 'x']
Iterating a dict gives its keys; sorting them by their values (1, 2, 3) gives y, z, x.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
What is the output of the Python code: print(sum(i for i in range(1, 6) if i % 2 == 0)) ?
सही उत्तर: घ) 6
The even numbers from 1 to 5 are 2 and 4, whose sum is 6.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
What is the output of the Python code: print(int('ff', 16) + int('17', 8)) ?
सही उत्तर: ख) 270
int('ff', 16) = 255 and int('17', 8) = 15, so the sum is 270.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
In Python the modulo result takes the sign of the divisor. Given that rule, what does print(7 % -3) display?
सही उत्तर: क) -2
In Python the result of % has the sign of the divisor: 7 = (-3) * (-3) + (-2).
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
What is the output of the Python code: x = 5; x //= 2; x **= 3; print(x) ?
सही उत्तर: ख) 8
5 // 2 = 2, and 2 ** 3 = 8.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
-
A Python range is given a start, a stop and a step of 5. What does print(list(range(2, 20, 5))) show?
सही उत्तर: क) [2, 7, 12, 17]
range starts at 2 and adds 5 each time while staying below 20.
💬 टिप्पणी / गल्ती रिपोर्ट (०)
यी अभ्यास प्रश्न हुन्, आधिकारिक प्रश्न होइनन्। पाठ्यक्रम, विज्ञापन र नतिजाका लागि सम्बन्धित निकायको आधिकारिक वेबसाइट हेर्नुहोस्। उत्तरमा गल्ती भेटे प्रश्नमुनिको "टिप्पणी / गल्ती रिपोर्ट" मा लेख्नुहोस्।
नमस्ते! पाठ्यक्रम, सामान्य ज्ञान, भाषा परीक्षा वा कुनै प्रश्नको उत्तर बुझ्न सोध्नुहोस्।
AI ले गल्ती गर्न सक्छ। महत्वपूर्ण कुरा आधिकारिक स्रोतमा जाँच्नुहोस्।