Java MCQ Questions and Answers pdf in Hindi English
Hello friends in this article you can find your query related to Core Java mcq questions and answers pdf, Core Java interview questions and answers, Java question answer download pdf in Hindi, Java question answer pdf,
Advanced Java programming question bank with answer, Basic Java programming questions and answers, Java interview question and answer for fresher, Java programming interview questions and answers
Java Interview Questions and Answers
Advanced Java question answer, Core Java question and answer, Java basic questions and answers, Java fundamentals question and answer, Java interview questions and answers for experience, Java question and answer in Hindi, Java question bank with answers pdf
Java MCQ Questions and Answers pdf
1. Who invented Java Programming?
जावा प्रोग्रामिंग का आविष्कार किसने किया?
a) Guido van Rossum
b) James Gosling
c) Dennis Ritchie
d) Bjarne Stroustrup
2. Which statement is true about Java?
जावा के बारे में कौन सा कथन सत्य है?
a) Java is a sequence-dependent programming language
b) Java is a code dependent programming language
c) Java is a platform-dependent programming language
d) Java is a platform-independent programming language
3. Which component is used to compile, debug and execute the java programs?
जावा प्रोग्रामों को संकलित, डिबग और निष्पादित करने के लिए किस घटक का उपयोग किया जाता है?
a) JRE
b) JIT
c) JDK
d) JVM
4. Which one of the following is not a Java feature?
निम्नलिखित में से कौन जावा फीचर नहीं है?
a) Object-oriented
b) Use of pointers
c) Portable
d) Dynamic and Extensible
5. Which of these cannot be used for a variable name in Java?
जावा में वेरिएबल नेम के लिए इनमें से किसका उपयोग नहीं किया जा सकता है?
a) identifier & keyword
b) identifier
c) keyword
d) none of the mentioned
6. What is the extension of java code files?
जावा कोड फाइलों का विस्तार क्या है?
a) .js
b) .txt
c) .class
d) .java
7. Which environment variable is used to set the java path?
जावा पथ को सेट करने के लिए किस पर्यावरण चर का उपयोग किया जाता है?
a) MAVEN_Path
b) JavaPATH
c) JAVA
d) JAVA_HOME
8. Which of the following is not an OOPS concept in Java?
निम्नलिखित में से कौन जावा में OOPS अवधारणा नहीं है?
a) Polymorphism
b) Inheritance
c) Compilation
d) Encapsulation
9. What is not the use of “this” keyword in Java?
जावा में “this” कीवर्ड का क्या उपयोग नहीं है?
a) Referring to the instance variable when a local variable has the same name
b) Passing itself to the method of the same class
c) Passing itself to another method
d) Calling another constructor in constructor chaining
10. Which of the following is a type of polymorphism in Java Programming?
निम्नलिखित में से कौन जावा प्रोग्रामिंग में एक प्रकार का बहुरूपता है?
a) Multiple polymorphism
b) Compile time polymorphism
c) Multilevel polymorphism
d) Execution time polymorphism
Java MCQ Questions and Answers pdf in Hindi
11. What is Truncation in Java?
जावा में ट्रंकेशन क्या है?
a) Floating-point value assigned to a Floating type
b) Floating-point value assigned to an integer type
c) Integer value assigned to floating type
d) Integer value assigned to floating type
12. What is the extension of compiled java classes?
संकलित जावा क्लासेस का विस्तार क्या है?
a) .txt
b) .js
c) .class
d) .java
13. Which exception is thrown when java is out of memory?
जब जावा मेमोरी से बाहर हो जाता है तो कौन सा अपवाद फेंका जाता है?
a) MemoryError
b) OutOfMemoryError
c) MemoryOutOfBoundsException
d) MemoryFullException
14. Which of these are selection statements in Java?
इनमें से कौन जावा में सिलेक्शन स्टेटमेंट हैं?
a) break
b) continue
c) for()
d) if()
15. Which of these keywords is used to define interfaces in Java?
जावा में इंटरफेस को परिभाषित करने के लिए इनमें से किस कीवर्ड का उपयोग किया जाता है?
a) intf
b) Intf
c) interface
d) Interface
16. Which of the following is a superclass of every class in Java?
निम्नलिखित में से कौन जावा में प्रत्येक वर्ग का सुपरक्लास है?
a) Array List
b) Abstract class
c) Object class
d) String
17. Which of the below is not a Java Profiler?
निम्न में से कौन जावा प्रोफाइलर नहीं है?
a) JProfiler
b) Eclipse Profiler
c) JVM
d) JConsole
18. Which of these packages contains the exception Stack Overflow in Java?
इनमें से किस पैकेज में जावा में अपवाद स्टैक ओवरफ्लो है?
a) java.io
b) java.system
c) java.lang
d) java.util
19. Which of these statements is incorrect about Thread?
इनमें से कौन सा कथन थ्रेड के बारे में गलत है?
a) start() method is used to begin execution of the thread
b) run() method is used to begin execution of a thread before start() method in special cases
c) A thread can be formed by implementing Runnable interface only
d) A thread can be formed by a class that extends Thread class
20. Which of these keywords are used for the block to be examined for exceptions?
इनमें से कौन सा कीवर्ड अपवादों के लिए जांच किए जाने वाले ब्लॉक के लिए उपयोग किया जाता है?
a) check
b) throw
c) catch
d) try
Java MCQ Questions and Answers pdf in Hindi
21. Which one of the following is not an access modifier?
निम्नलिखित में से कौन एक एक्सेस मॉडिफायर नहीं है?
a) Protected
b) Void
c) Public
d) Private
22. What is the numerical range of a char data type in Java?
जावा में char डेटा प्रकार की संख्यात्मक सीमा क्या है?
a) 0 to 256
b) -128 to 127
c) 0 to 65535
d) 0 to 32767
23. Which class provides system independent server side implementation?
कौन सा वर्ग सिस्टम स्वतंत्र सर्वर साइड कार्यान्वयन प्रदान करता है?
a) Server
b) Server Reader
c) Socket
d) Server Socket
24. Which of the following is true about servlets?
सर्वलेट्स के बारे में निम्नलिखित में से कौन सा सत्य है?
a) Servlets can use the full functionality of the Java class libraries
b) Servlets execute within the address space of web server, platform independent and uses the functionality of java class libraries
c) Servlets execute within the address space of web server
d) Servlets are platform-independent because they are written in java
25. In java control statements break, continue, return, try-catch-finally and assert belongs to?
जावा कंट्रोल स्टेटमेंट में ब्रेक, जारी, रिटर्न, ट्राई-कैच-आखिरकार और एस्टर का संबंध है?
a) Selection statements
b) Loop Statements
c) Transfer statements
d) Pause Statement
26. Which provides runtime environment for java byte code to be executed?
जो जावा बाइट कोड को निष्पादित करने के लिए रनटाइम वातावरण प्रदान करता है?
a) JDK
b) JVM
c) JRE
d) JAVAC
27. What is byte code in Java?
जावा में बाइट कोड क्या है?
a) Code generated by a Java compiler
b) Code generated by a Java Virtual Machine
c) Name of Java source code file
d) Block of code written inside a class
28. Which of the following are not Java keywords?
निम्नलिखित में से कौन जावा कीवर्ड नहीं हैं?
a) double
b) switch
c) then
d) instanceof
29. Which of these have highest precedence?
इनमें से किसकी सर्वोच्च प्राथमिकता है?
a) ()
b) ++
c) *
d) >>
30. Which of these is returned by operator ‘&’ ?
इनमें से कौन सा ऑपरेटर ‘&’ द्वारा वापस किया जाता है?
a) Integer
b) Character
c) Boolean
d) Float
Java MCQ Questions and Answers pdf in Hindi
31. Data type long literals are appended by _____
डेटा प्रकार long literals _____ द्वारा जोड़े जाते हैं
a) Uppercase L
b) Lowercase L
c) Long
d) Both A and B
32. Which variables are created when an object is created with the use of the keyword ‘new’ and destroyed when the object is destroyed?
जब कोई वस्तु ‘new’ कीवर्ड के उपयोग से बनाई जाती है और object destroyed होने पर destroyed हो जाती है तो कौन से चर बनते हैं?
a) Local variables
b) Instance variables
c) Class Variables
d) Static variables
33. Java language was initially called as ________
जावा भाषा को शुरू में ________ कहा जाता था।
a) Sumatra
b) J++
c) Oak
d) Pine
34. What is garbage collection in the context of Java?
जावा के संदर्भ में garbage collection क्या है?
a) Java deletes all unused java files on the system.
b) Memory used by the object with no reference is automatically reclaimed.
c) The JVM cleans output of Java program with error.
d) Any unused package in a program automatically gets deleted.
35. Which one is a template for creating different objects?
विभिन्न objects को बनाने के लिए कौन सा टेम्पलेट है?
a) An Array
b) A class
c) Interface
d) Method
36. Which symbol is used to contain the values of automatically initialized arrays?
स्वचालित रूप से आरंभिक सरणियों के मान रखने के लिए किस प्रतीक का उपयोग किया जाता है?
a) Brackets
b) Braces
c) Parentheses
d) Comma
37. Which one is true about a constructor?
कंस्ट्रक्टर के बारे में कौन सा सत्य है?
a) A constructor must have the same name as the class it is declared within.
b) A constructor is used to create objects.
c) A constructor may be declared private
d) All of the above
38. Which of these operators is used to allocate memory to array variable in Java?
जावा में ऐरे वेरिएबल में मेमोरी आवंटित करने के लिए इनमें से किस ऑपरेटर का उपयोग किया जाता है?
a) alloc
b) malloc
c) new malloc
d) new
39. Which of these is not a bitwise operator?
इनमें से कौन सा बिटवाइज़ ऑपरेटर नहीं है?
a) &’ Operator
b) &=’ Operator
c) |=’ Operator
d) <=’ Operator
40. Which of these is returned by Greater Than, Less Than and Equal To (i.e Relational) operator?
इनमें से कौन Greater Than, Less Than and Equal To (यानी रिलेशनल) ऑपरेटर द्वारा लौटाया जाता है?
a) Fload
b) Integer
c) Boolean
d) Double
Java MCQ Questions and Answers pdf in Hindi
41. Which statement transfer execution to different parts of your code based on the value of an expression?
एक एक्सप्रेशन के मान के आधार पर आपके कोड के विभिन्न हिस्सों में कौन सा स्टेटमेंट एक्ज़ीक्यूशन ट्रांसफर करता है?
a) If
b) Switch
c) Nested-if
d) if-else-if
42. Modulus operator (%) can be applied to which of these?
मापांक ऑपरेटर (%) इनमें से किस पर लागू किया जा सकता है?
a) Integers
b) Floating – point numbers
c) Both A and B
d) None of These
43. What feature of OOP has a super-class sub-class concept?
OOP की किस विशेषता में सुपर-क्लास सब-क्लास अवधारणा है?
a) Hierarchical inheritance
b) Single inheritance
c) Multiple inheritances
d) Multilevel inheritance
44. Which of the following are not the methods of the Thread class?
निम्नलिखित में से कौन सी थ्रेड क्लास की विधियाँ नहीं हैं?
a) yield()
b) sleep(long msec)
c) go()
d) stop()
45. Division operator has ____ precedence over multiplication operator.
डिवीजन ऑपरेटर की गुणन ऑपरेटर पर ____ प्राथमिकता होती है।
a) Heighest
b) Least
c) Equal
d) None of These
46. What is the full form of JVM?
जेवीएम का फुल फॉर्म क्या है?
a) Java Very Large Machine
b) Java Verified Machine
c) Java Very Small Machine
d) Java Virtual Machine
47. In Java code, the line that begins with /* and ends with */ is known as?
जावा कोड में वह Line जो /* से शुरू होती है और */ से समाप्त होती है, कहलाती है?
a) Multiline comment
b) Single line comment
c) Both A & B
d) None of these
48. Which of the following are not Java modifiers?
निम्नलिखित में से कौन जावा संशोधक नहीं हैं?
a) public
b) private
c) friendly
d) transient
49. Which of the following statements about the Java language is true?
जावा भाषा के बारे में निम्नलिखित में से कौन सा कथन सत्य है?
a) Java supports only Procedural Oriented Programming approach
b) Both Procedural and Object Oriented Programming are supported in Java
c) Java supports only Object Oriented Programming approach
d) None of the Above
50. JRE stands for _______________.
JRE का मतलब __________ है।
a) Java Realtime Environment
b) Java Rapid Enterprise
c) Java Runtime Environment
d) None of the above
Also Read: HTML Interview questions and answers in Hindi and English
51. Java source files are compiled and converted to ___________.
जावा स्रोत फ़ाइलें संकलित और ___________ में परिवर्तित की जाती हैं।
a) Object code
b) Machine code
c) Bytecode
d) Executable file
52. JVM is ___________for bytecode.
जेवीएम बायटेकोड के लिए ___________ है।
a) A compiler
b) An interpreter
c) Assembler
d) None of the above
53. What is the size of int data type in java?
जावा में int डेटा प्रकार का आकार क्या है?
a) 1 bytes
b) 2 bytes
c) 4 bytes
d) 8 bytes
54. Which is a valid float literal?
एक valid float literal कौन सा है?
a) 1.23
b) 2
c) 1.23d
d) 1.23f
55. What is the numerical range of a char in Java?
जावा में char की संख्यात्मक सीमा क्या है?
a) -128 to 127
b) 0 to 256
c) 0 to 32767
d) 0 to 65535
56. Which of these coding types is used for data type char in Java?
जावा में डेटा टाइप char के लिए इनमें से किस कोडिंग प्रकार का उपयोग किया जाता है?
a) ASCII
b) ISO-LATIN-1
c) UNICODE
d) None of the above
57. Which of these values can a boolean variable contain?
बूलियन वेरिएबल में इनमें से कौन सा मान हो सकता है?
a) True & False
b) 0 & 1
c) Any integer value
d) Both a & b
58. Which one of the following is a valid identifier in java?
निम्नलिखित में से कौन जावा में एक valid identifier है?
a) x1
b) 1x
c) $x
d) x 1
59. Which operator is used to implement unsigned right shift of an integer?
एक integer की unsigned right shift को लागू करने के लिए किस ऑपरेटर का उपयोग किया जाता है?
a) <<
b) >>
c) <<<
d) >>>
60. Which one of the following is a jump statement in java?
निम्नलिखित में से कौन जावा में जम्प स्टेटमेंट है?
a) goto
b) jump
c) break
d) if
Java MCQ Questions and Answers pdf in Hindi
61. Which of these operators is used to allocate memory to array variable in Java?
जावा में ऐरे वेरिएबल में मेमोरी आवंटित करने के लिए इनमें से किस ऑपरेटर का उपयोग किया जाता है?
a) malloc
b) alloc
c) new
d) new malloc
62. Which of the following loops will execute the body of loop even when condition controlling the loop is initially false?
निम्नलिखित में से कौन सा loop, body of loop को निष्पादित करेगा, भले ही loop को नियंत्रित करने वाली स्थिति शुरू में false हो?
a) do-while
b) while
c) for
d) None of the above
63. Which of these is necessary condition for automatic type conversion in Java?
जावा में स्वचालित प्रकार के रूपांतरण के लिए इनमें से कौन सी आवश्यक शर्त है?
a) The destination type is smaller than source type
b) The destination type is larger than source type
c) The destination type can be larger or smaller than source type
d) None of the above
64. What is the error in this code? byte b = 50; b = b * 50;
इस कोड में क्या त्रुटि है? byte b = 50; b = b * 50;
a) b can not store the result 2500, limited by its range
b) * operator has converted b * 50 into int, which can not be converted to byte without casting
c) b can not contain value 50
d) No error in this code
65. Which of these is an incorrect array declaration?
इनमें से कौन एक गलत एरे डिक्लेरेशन है?
a) int arr[] = new int[5];
b) int [] arr = new int[5];
c) int arr[]; arr = new int[5];
d) int arr[] = int [5] new
66. Which of these selection statements test only for equality?
इनमें से कौन सा selection statements केवल equality के लिए परीक्षण करता है?
a) if
b) switch
c) Both a & b
d) None of the above
67. Which of these are selection statements in Java?
इनमें से कौन जावा में सिलेक्शन स्टेटमेंट हैं?
a) if
b) for
c) continue
d) All of these
68. Which of these jump statements can skip processing remainder of code in its body for a particular iteration?
इनमें से कौन सा जंप स्टेटमेंट किसी विशेष पुनरावृत्ति के लिए अपने body में शेष कोड को संसाधित करना छोड़ सकता है?
a) break
b) return
c) exit
d) continue
69. What is the value of the expression 2 & 3?
व्यंजक 2 और 3 का मान क्या है?
a) 2
b) 3
c) 6
d) 5
70. What is the value of the expression 8 << 2 ?
व्यंजक 8 << 2 का मान क्या है?
a) 2
b) 32
c) 1 6
d) 5
Java MCQ Questions and Answers pdf in Hindi
71. The keyword used to create a constant variable is ________.
एक स्थिर चर बनाने के लिए प्रयुक्त कीवर्ड ________ है।
a) const
b) static
c) final
d) None of these
72. What is stored in the object obj in following lines of code? box obj;
कोड की निम्नलिखित पंक्तियों में ऑब्जेक्ट obj में क्या संग्रहीत किया जाता है? Box obj;
a) Memory address of allocated memory of object
b) NULL
c) Any arbitrary pointer
d) Garbage
73. Every statement in Java language should end with a _______.
जावा भाषा में प्रत्येक कथन _______ के साथ समाप्त होना चाहिए।
a) Dot or Period
b) Comma
c) Semicolon
d) Colon
74. A function in C language is similar to what in Java language?
C भाषा में एक फ़ंक्शन जावा भाषा के समान है?
a) Method
b) Member
c) Variable
d) None of the above
75. Variables declared with in a class are called _________.
एक वर्ग में घोषित चर _________ कहलाते हैं।
a) Identifier
b) Local variable
c) Instance variable
d) Global variable
76. Variables declared within a method or block are called __________.
एक method या block के भीतर घोषित चर __________ कहलाते हैं।
a) Static variable
b) local variable
c) instance variable
d) global variable
77. All methods and variables in Java language are kept inside a _________.
जावा भाषा में सभी विधियों और चरों को _________ के अंदर रखा जाता है।
a) File
b) Class or Interface
c) Static method
d) main
78. What is the need to mention “static” before main method?
main method से पहले “static” का उल्लेख करने की क्या आवश्यकता है?
a) To call main method without creating an object of class
b) To make main method as class method common to all instances
c) Both A and B
d) None of the above
79. In standalone Java applications, which method is mandatory?
स्टैंडअलोन जावा अनुप्रयोगों में, कौन सी विधि अनिवार्य है?
a) main method
b) show method
c) display method
d) print method
80. What is the use of Access modifier “public” in Java language?
जावा भाषा में Access modifier “public” का क्या उपयोग है?
a) To hide the main method from misuse
b) To call the main method outside of Class or Package by JVM
c) To protect main method
d) None of the above
Java MCQ Questions and Answers pdf in Hindi
81. What is the default return type of a method in Java language?
जावा भाषा में एक विधि का डिफ़ॉल्ट रिटर्न प्रकार क्या है?
a) void
b) int
c) short
d) None of the above
82. Name of a Class, Variable, Method or an Interface in Java language is called?
जावा भाषा में एक क्लास, वेरिएबल, मेथड या एक इंटरफेस का नाम क्या कहलाता है?
a) Argument
b) Value
c) Identifier
d) None of the above
83. A valid identifier in Java language may contain which characters?
जावा भाषा में एक valid identifier में कौन से character हो सकते हैं?
a) 0-9
b) A-Z, a-z
c) $, _ (Underscore)
d) All the above
84. A valid Identifier or name in Java language can start with which character?
जावा भाषा में एक valid identifier या नाम किस character से शुरू हो सकता है?
a) a-z, A-Z
b) $, _
c) 0-9
d) Both A and B
85. What are the valid White Spaces available in Java language?
जावा भाषा में उपलब्ध valid White Spaces क्या हैं?
a) Space
b) Enter
c) Tab
d) All the above
86. What is a Primitive Data Type in Java?
जावा में एक Primitive Data Type क्या है?
a) Data type, which is implemented in an Object-oriented way
b) Data Type which is implemented in a machine-dependent way
c) Data Type which is implemented in a non-object oriented way
d) None of the above
87. Which among the following is not a Data Type in Java?
निम्नलिखित में से कौन जावा में डेटा टाइप नहीं है?
a) short
b) int
c) long double
d) double
88. Which of the following below live on the heap in java?
निम्नलिखित में से कौन जावा में heap पर रहता है?
a) Class
b) Instance variable
c) Method
d) Object
89. Which of these interfaces handle sequences?
इनमें से कौन सा इंटरफेस सीक्वेंस को हैंडल करता है?
a) Set
b) List
c) Comparator
d) Collection
90. Which of this interface must contain a unique element?
इनमें से किस इंटरफ़ेस में एक अद्वितीय तत्व होना चाहिए?
a) Set
b) List
c) Array
d) Collection
Java MCQ Questions and Answers pdf in Hindi
91. Which statement about a valid .java file is true?
वैध .java फ़ाइल के बारे में कौन सा कथन सत्य है?
a) It can only contain one class declaration
b) It can contain one public class declaration and one public interface definition
c) It must define at least one public class
d) It may define at most one public class
92. Which is correct about an instance variable of type String?
स्ट्रिंग प्रकार के आवृत्ति चर के बारे में कौन सा सही है?
a) It defaults to an empty string
b) It defaults to null
c) It does not have a default value
d) It will not compile without initializing on the declaration line
93. Which of the following is true about primitives?
Primitives के बारे में निम्नलिखित में से कौन सा सत्य है?
a) You can call methods on a primitive
b) You can convert a primitive to a wrapper class object simply by assigning it
c) You can convert a wrapper class object to a primitive by calling valueOf()
d) You can store a primitive directly into an Array List
94. The wrapping up of data and functions into a single unit is called___________.
डेटा और फंक्शन को एक इकाई में लपेटने को ___________ कहा जाता है।
a) Encapsulation
b) Abstraction
c) Data Hiding
d) Polymorphism
95. In object-oriented programming, new classes can be defined by extending existing classes. This is an example of _________.
ऑब्जेक्ट-ओरिएंटेड प्रोग्रामिंग में, मौजूदा classes का विस्तार करके नई classes को परिभाषित किया जा सकता है। यह _________ का उदाहरण है।
a) Encapsulation
b) Interface
c) Composition
d) Inheritance
96. What do you mean by >>> operator in Java?
जावा में >>> ऑपरेटर से आपका क्या तात्पर्य है?
a) Left Shift Operator
b) Right Shift Operator
c) Zero Fill Right Shift
d) Zero Fill Left Shift
97. Which of the following is not an operator in Java?
निम्नलिखित में से कौन जावा में एक ऑपरेटर नहीं है?
a) |
b) ^
c) ~
d) <->
98. Java supports both Primitive & Non-Primitive (User Defined) data types. Which one of the following is not a primitive data type?
जावा primitive और non-primitive (उपयोगकर्ता परिभाषित) दोनों प्रकार के डेटा प्रकारों का समर्थन करता है। निम्नलिखित में से कौन एक primitive डेटा प्रकार नहीं है?
a) byte
b) short
c) long
d) class
99. Which of these are Access Modifiers in java?
इनमें से कौन जावा में एक्सेस मॉडिफायर हैं?
a) default
b) public
c) protected
d) All of these
100. What is correct sequence of execution of any Java program?
किसी भी जावा प्रोग्राम के निष्पादन का सही क्रम क्या है?
a) Editing -> Compilation -> Class Loader -> Bytecode Verifier -> Execution
b) Editing -> Bytecode Verifier -> Compilation -> Class Loader -> Execution
c) Editing -> Compilation -> Bytecode Verifier -> Class Loader -> Execution
d) None of the above
So friends I hope you enjoy this article about Java MCQ Questions and Answers pdf, Java Interview Questions and Answers, Java Question Answer download pdf in Hindi, Java questions for freshers
Java Question Answer download pdf
File Name | Java MCQ Questions and Answers pdf |
File Size | 720 KB |
No. of Pages | 26 |
Language | Hindi and English |
Download | Click Here |
Related Searches: Java questions asked in interview, java questions for practice, multiple choice question and answer in java, question and answer for java programming, java coding interview questions and answers, java developer interview questions and answers, java program question and answer, question and answer for java programming