[C-Sharp Programming MCQS ]

झारखंड में आयोजित होने वाली JPSC, JSSC, JET, झारखंड पुलिस भर्ती परीक्षा आदि के लिए उपयोगी सामान्य अध्ययन।

[ C-Sharp Programming MCQS ]

Useful GK for JPSC, JSSC, JET, Jharkhand Police and other exams.
331. ThreadPool का मुख्य लाभ क्या है?
[A] New thread हर बार create करना
[B] Reuse of existing threads
[C] Database connection
[D] File system access
331. What is the main advantage of ThreadPool?
[A] Create new thread every time
[B] Reuse existing threads
[C] Database connection
[D] File system access
सही उत्तर: Reuse of existing threads
व्याख्या: महत्वपूर्ण प्रश्न।
Correct Answer: Reuse existing threads
Explanation: Important question.
332. Race condition कब होती है?
[A] Single thread execution में
[B] Multiple threads shared data access करते समय
[C] Memory free होने पर
[D] Program start होने पर
332. When does a race condition occur?
[A] Single thread execution
[B] When multiple threads access shared data
[C] When memory is free
[D] At program start
सही उत्तर: Multiple threads shared data access करते समय
व्याख्या: महत्वपूर्ण प्रश्न।
Correct Answer: When multiple threads access shared data
Explanation: Important question.
333. Interlocked class का उपयोग किसलिए होता है?
[A] Atomic operations के लिए
[B] File operations के लिए
[C] Database queries के लिए
[D] UI rendering के लिए
333. What is the use of Interlocked class?
[A] Atomic operations
[B] File operations
[C] Database queries
[D] UI rendering
सही उत्तर: Atomic operations के लिए
व्याख्या: महत्वपूर्ण प्रश्न।
Correct Answer: Atomic operations
Explanation: Important question.
334. Deadlock से बचने का सबसे अच्छा तरीका क्या है?
[A] Infinite loops
[B] Proper lock ordering
[C] Memory increase
[D] Thread kill करना
334. What is the best way to avoid deadlock?
[A] Infinite loops
[B] Proper lock ordering
[C] Increase memory
[D] Kill threads
सही उत्तर: Proper lock ordering
व्याख्या: महत्वपूर्ण प्रश्न।
Correct Answer: Proper lock ordering
Explanation: Important question.
335. Task Parallel Library (TPL) का मुख्य उद्देश्य क्या है?
[A] Database design
[B] Parallel programming simplify करना
[C] File system delete करना
[D] Memory allocation
335. What is the main purpose of Task Parallel Library (TPL)?
[A] Database design
[B] Simplify parallel programming
[C] Delete file system
[D] Memory allocation
सही उत्तर: Parallel programming simplify करना
व्याख्या: महत्वपूर्ण प्रश्न।
Correct Answer: Simplify parallel programming
Explanation: Important question.
336. async/await का मुख्य लाभ क्या है?
[A] Thread blocking
[B] Non-blocking asynchronous programming
[C] Memory leak
[D] CPU slowdown
336. What is the main benefit of async/await?
[A] Thread blocking
[B] Non-blocking asynchronous programming
[C] Memory leak
[D] CPU slowdown
सही उत्तर: Non-blocking asynchronous programming
व्याख्या: महत्वपूर्ण प्रश्न।
Correct Answer: Non-blocking asynchronous programming
Explanation: Important question.
337. C# में async method हमेशा क्या return करता है?
[A] void या int
[B] Task या Task
[C] string
[D] object
337. What does an async method always return in C#?
[A] void or int
[B] Task or Task
[C] string
[D] object
सही उत्तर: Task या Task
व्याख्या: महत्वपूर्ण प्रश्न।
Correct Answer: Task or Task
Explanation: Important question.
338. async void का मुख्य उपयोग कहाँ होता है?
[A] Business logic में
[B] Event handlers में
[C] Database layer में
[D] Thread pool में
338. Where is async void mainly used?
[A] Business logic
[B] Event handlers
[C] Database layer
[D] Thread pool
सही उत्तर: Event handlers में
व्याख्या: महत्वपूर्ण प्रश्न।
Correct Answer: Event handlers
Explanation: Important question.
339. Deadlock avoid करने के लिए best practice क्या है?
[A] Random locking
[B] Consistent lock ordering
[C] Infinite wait
[D] Thread abort
339. What is the best practice to avoid deadlock?
[A] Random locking
[B] Consistent lock ordering
[C] Infinite wait
[D] Thread abort
सही उत्तर: Consistent lock ordering
व्याख्या: महत्वपूर्ण प्रश्न।
Correct Answer: Consistent lock ordering
Explanation: Important question.
340. ConfigureAwait(false) का मुख्य effect क्या होता है?
[A] Thread increase करता है
[B] Context switching avoid करता है
[C] Memory leak करता है
[D] Exception throw करता है
340. What is the main effect of ConfigureAwait(false)?
[A] Increases threads
[B] Avoids context switching
[C] Causes memory leak
[D] Throws exception
सही उत्तर: Context switching avoid करता है
व्याख्या: महत्वपूर्ण प्रश्न।
Correct Answer: Avoids context switching
Explanation: Important question.