[Programming MCQS ]

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

[ Programming MCQS ]

Useful GK for JPSC, JSSC, JET, Jharkhand Police and other exams.
41. निम्न में से कौन standard arithmetic operator नहीं है?
[A] ^
[B] *
[C] +
[D] /
41. Which of the following is NOT a standard arithmetic operator in C?
[A] ^
[B] *
[C] +
[D] /
सही उत्तर: A
व्याख्या: ^ operator bitwise XOR के लिए उपयोग होता है।
Correct Answer: A
Explanation: ^ is a bitwise XOR operator.
42. Function में return statement का उद्देश्य क्या है?
[A] To terminate the program
[B] To print a value
[C] To declare a variable
[D] To exit the current function and return a value
42. What is the purpose of the “return” statement in a function?
[A] To terminate the program
[B] To print a value
[C] To declare a variable
[D] To exit the current function and return a value
सही उत्तर: D
व्याख्या: return statement function से value वापस भेजता है।
Correct Answer: D
Explanation: return exits the function and sends back a value.
43. switch statement का उपयोग किसलिए किया जाता है?
[A] Declaring variables
[B] Defining functions
[C] Conditional branching
[D] Looping
43. The “switch” statement is used for:
[A] Declaring variables
[B] Defining functions
[C] Conditional branching
[D] Looping
सही उत्तर: C
व्याख्या: switch multiple conditions handle करने के लिए उपयोग होता है।
Correct Answer: C
Explanation: switch is used for conditional branching.
44. include directive की भूमिका क्या है?
[A] It includes a library function
[B] It imports external code
[C] It defines a new function
[D] It declares a variable
44. What is the role of the “include” directive in C?
[A] It includes a library function
[B] It imports external code
[C] It defines a new function
[D] It declares a variable
सही उत्तर: B
व्याख्या: #include external header files को program में जोड़ता है।
Correct Answer: B
Explanation: #include imports external header files.
45. Arrays के बारे में कौन सा statement सही है?
[A] Arrays can hold only one data type
[B] Arrays are dynamic in size
[C] Arrays can be resized during runtime
[D] Arrays are a collection of similar data types
45. Which of the following is true about arrays in C?
[A] Arrays can hold only one data type
[B] Arrays are dynamic in size
[C] Arrays can be resized during runtime
[D] Arrays are a collection of similar data types
सही उत्तर: D
व्याख्या: Array समान data types का collection होता है।
Correct Answer: D
Explanation: Arrays store similar types of data.
46. C में strings को कैसे represent किया जाता है?
[A] As character arrays
[B] As integer arrays
[C] As floating-point arrays
[D] As boolean arrays
46. How are strings represented in C?
[A] As character arrays
[B] As integer arrays
[C] As floating-point arrays
[D] As boolean arrays
सही उत्तर: A
व्याख्या: Strings character array के रूप में store होती हैं।
Correct Answer: A
Explanation: Strings are represented as character arrays.
47. sizeof operator का उद्देश्य क्या है?
[A] It returns the size of a variable in bytes
[B] It performs arithmetic operations
[C] It compares two variables
[D] It converts data types
47. What is the purpose of the “sizeof” operator in C?
[A] It returns the size of a variable in bytes
[B] It performs arithmetic operations
[C] It compares two variables
[D] It converts data types
सही उत्तर: A
व्याख्या: sizeof किसी variable/data type का size bytes में बताता है।
Correct Answer: A
Explanation: sizeof returns memory size in bytes.
48. Pointer declare करने के लिए कौन सा symbol उपयोग होता है?
[A] *
[B] &
[C] $
[D] #
48. Which of the following is used to declare a pointer in C?
[A] *
[B] &
[C] $
[D] #
सही उत्तर: A
व्याख्या: * symbol pointer declaration के लिए उपयोग होता है।
Correct Answer: A
Explanation: * is used to declare pointers.
49. NULL pointer किसको point करता है?
[A] The end of a string
[B] A random memory location
[C] Nothing or no memory location
[D] A predefined function
49. What does the “NULL” pointer point to in C?
[A] The end of a string
[B] A random memory location
[C] Nothing or no memory location
[D] A predefined function
सही उत्तर: C
व्याख्या: NULL pointer किसी valid memory location को point नहीं करता।
Correct Answer: C
Explanation: NULL points to no valid memory location.
50. Constant define करने के लिए कौन सा keyword उपयोग होता है?
[A] const
[B] static
[C] define
[D] constant
50. Which keyword is used to define a constant in C?
[A] const
[B] static
[C] define
[D] constant
सही उत्तर: A
व्याख्या: const keyword constant values define करने के लिए उपयोग होता है।
Correct Answer: A
Explanation: const defines constant values.