Open navigation menu
Close suggestions
Search
Search
en
Change Language
Upload
Sign in
Sign in
Download free for days
0 ratings
0% found this document useful (0 votes)
7 views
Top 34 Java Basic Interview Question Answers
Java interview questions
Uploaded by
Mr fresh Asian
Copyright
© © All Rights Reserved
Available Formats
Download as PDF or read online on Scribd
Download now
Download
Save Top 34 Java Basic Interview Question Answers For Later
Download
Save
Save Top 34 Java Basic Interview Question Answers For Later
0%
0% found this document useful, undefined
0%
, undefined
Embed
Share
Print
Report
0 ratings
0% found this document useful (0 votes)
7 views
Top 34 Java Basic Interview Question Answers
Java interview questions
Uploaded by
Mr fresh Asian
Copyright
© © All Rights Reserved
Available Formats
Download as PDF or read online on Scribd
Download now
Download
Save Top 34 Java Basic Interview Question Answers For Later
Carousel Previous
Carousel Next
Save
Save Top 34 Java Basic Interview Question Answers For Later
0%
0% found this document useful, undefined
0%
, undefined
Embed
Share
Print
Report
Download now
Download
You are on page 1
/ 7
Search
Fullscreen
1. What is Java? | © (Java is a high-level, object-oriented programming \designed to have minimal implementation dependencies, language developed by Sun Microsystems in 1995. It's making it platform- independent. 2. What is the JDK? ° |The JDK (Java Development Kit) is a software development lenvironment used for developing Java applications. It lincludes the Java Runtime Environment (JRE), a compiler, |and other development tools. 3.\What is the JRE? © The JRE (Java Runtime Environment) is the runtime portion of Java software, which is all you need to run Java japplications but not to develop them 4. What is the JVM? Othe JVM (Java Virtual Machine) is a platform-independent \execution environment that converts Java bytecode into machine language and executes it.5. What is bytecode? © Bytecode is the intermediate code generated after the Java compiler compiles the source code. It is platform- independent and can be executed by the JVM. 6. What is the difference between JDK, JRE, and JVM? ° + JDK: For development (contains JRE + tools for development). + JRE: For running Java applications (contains JVM + libraries). + JVM: For executing bytecode (runs Java programs). 7.1s Java platform-independent? Why? © Yes, Java is platform-independent because of its bytecode that can run on any system that has a JVM, regardless of the underlying architecture. 8. What is the main feature of the Java language? © The primary feature of Java is platform independence, achieved through the use of the JVM. 9. What is object-oriented programming (oop)?© 00? is a programming paradigm that relies on the concept of classes and objects. Key principles of OOP include encapsulation, inheritance, polymorphism, and abstraction. 10. What is a class in Java? © A class in Java is a blueprint from which objects are created. It can contain fields (attributes) and methods (functions) to define the behavior and state of objects. ll. What is an object in Java? © An object is an instance of a class. It is a real-world entity that holds state and behavior defined by its class ___12.|What is encapsulation? eo Encapsulation is the wrapping of data (tields) and code (methods) into a single unit, known as a class, and restricting direct access to some components. 13.|What is inheritance? © Inheritance is a mechanism where one class acquires the properties (fields and methods) of another class. It helps in code reusability. 14. What is polymorphism?© Polymorphism is the ability of a method to perform different functions based on the object that it is acting upon. It allows one interface to be used for a general class of actions. 15. What is abstraction? © Abstraction is the concept of hiding the internal implementation of a feature and only exposing the functionality to the user. 16. What is the difference between an interface and an abstract class? © - Interface: Can only have abstract methods and final fields (Java 8+ allows default and static methods). + Abstract class: Can have both abstract and concrete methods and can hold state. 17. What is a constructor in Java? © Aconstructor is a special method used to initialize objects. It is invoked when an object of a class is created. 18.|What is the default constructor? © A default constructor is a constructor provided by Java if no other constructors are defined in the class. It has no parameters.19..What is method overloading? © Method overloading is when a class has more than one method with the same name but different parameter lists (either in number or type). 20. What is method overriding? © Method overriding occurs when a subclass provides a specific implementation of a method that is already defined in its superclass. 21.\What is the 'super' keyword in Java? © The super keyword refers to the immediate parent class object. It is used to access parent class methods or constructors. 22. What is a package in Java? A package is a namespace that organizes classes and interfaces. It helps to avoid name conflicts and to control _ access. 23.|What is the use of the ‘final’ keyword? eo The final keyword can be used with classes, methods, and variables to indicate that they cannot be modified or extended.24. What is the static keyword? © The static keyword in Java is used for memory management. It can be applied to variables, methods, blocks, and nested classes. Static members belong to the class rather than instances. 25. What is the difference between static and instance variables? @ - Static variables are shared among all instances of a class. + Instance variables are unique to each instance of a class. 26. What is the 'this' keyword in Java? °° ‘The This keyword is used to refer to the current instance of the class. 27. What is exception handling? © Exception handling in Java is a mechanism to handle runtime errors, allowing normal flow of the application even after an error occurs. 28. What is the difference between checked and unchecked exceptions? © ° Checked exceptions are checked at compile-time. + Unchecked exceptions are checked at runtime (subclasses of RuntimeException).29. What is the try-catch block? © The try block contains code that might throw an exception, while the catch block handles the exception if it occurs. 30. What is the finally block in Java? © The finally block contains code that is always executed, regardless of whether an exception is thrown or caught. 31. What is the throw keyword in Java? © The throw keyword is used to explicitly throw an exception. 32. What is the throws keyword? © The throws keyword is used in method signatures to declare that a method may throw exceptions. 33. What are collections in Java? © The Java Collections Framework provides a set of interfaces and classes to store and manipulate data in groups. 34.\What is the difference between an Array and an ArrayList? © : Arrays are of fixed size, while ArrayLists are resizable. + Arrays can hold primitive types, whereas ArrayLists hold objects.
You might also like
Java Interview Question
PDF
No ratings yet
Java Interview Question
2 pages
question and answer
PDF
No ratings yet
question and answer
28 pages
100 Most Asked Java Interview QnA
PDF
No ratings yet
100 Most Asked Java Interview QnA
15 pages
100 Most Asked Java Interview QnA
PDF
No ratings yet
100 Most Asked Java Interview QnA
13 pages
Beginner Level Java Viva or Interview Questions
PDF
No ratings yet
Beginner Level Java Viva or Interview Questions
13 pages
100 Most Asked Java Interview QnA PDF
PDF
No ratings yet
100 Most Asked Java Interview QnA PDF
15 pages
Java Interview Questions - Answers
PDF
No ratings yet
Java Interview Questions - Answers
4 pages
100 Most Asked Java Interview QnA
PDF
No ratings yet
100 Most Asked Java Interview QnA
12 pages
Jpr Question Answer
PDF
No ratings yet
Jpr Question Answer
7 pages
JAVA_VIVA_QA
PDF
No ratings yet
JAVA_VIVA_QA
8 pages
Basics of Java
PDF
No ratings yet
Basics of Java
9 pages
Java_OOPS_Viva_Questions_with_Answers
PDF
No ratings yet
Java_OOPS_Viva_Questions_with_Answers
6 pages
Java Interview Questions
PDF
No ratings yet
Java Interview Questions
22 pages
Top 50 Most Frequent Java Interview Questions & Answer
PDF
No ratings yet
Top 50 Most Frequent Java Interview Questions & Answer
24 pages
Java_InterviewQuestion_LinkedIn_JavaCommunity
PDF
No ratings yet
Java_InterviewQuestion_LinkedIn_JavaCommunity
45 pages
UNIT WISE 1 MARK QUESTION AND ANSWERS
PDF
No ratings yet
UNIT WISE 1 MARK QUESTION AND ANSWERS
14 pages
30 Question and Answer For PI
PDF
No ratings yet
30 Question and Answer For PI
4 pages
Interview Questions On Java
PDF
No ratings yet
Interview Questions On Java
9 pages
Fundamental of Java Programming Oral Question Bank
PDF
No ratings yet
Fundamental of Java Programming Oral Question Bank
12 pages
Java Interview Questions
PDF
No ratings yet
Java Interview Questions
8 pages
Java Interview Questions
PDF
No ratings yet
Java Interview Questions
13 pages
Latest Java Interview Question and Answers
PDF
No ratings yet
Latest Java Interview Question and Answers
8 pages
Java Interview Questions for Freshers
PDF
No ratings yet
Java Interview Questions for Freshers
73 pages
JF1 3
PDF
No ratings yet
JF1 3
3 pages
Java Interview Questions
PDF
No ratings yet
Java Interview Questions
20 pages
Java Notes by Bunny
PDF
No ratings yet
Java Notes by Bunny
57 pages
Answer Key for Java
PDF
No ratings yet
Answer Key for Java
2 pages
Java Viva
PDF
No ratings yet
Java Viva
6 pages
Interview Preparation
PDF
No ratings yet
Interview Preparation
33 pages
vvi
PDF
No ratings yet
vvi
16 pages
JAVA Interview Questions
PDF
No ratings yet
JAVA Interview Questions
6 pages
Core Java
PDF
50% (2)
Core Java
114 pages
Core Java Interview Ques
PDF
No ratings yet
Core Java Interview Ques
3 pages
JAVA
PDF
No ratings yet
JAVA
3 pages
Top 50 Java Interview Questions
PDF
No ratings yet
Top 50 Java Interview Questions
5 pages
Java Interview
PDF
No ratings yet
Java Interview
9 pages
Java Viva Question
PDF
No ratings yet
Java Viva Question
82 pages
2) What Are The Differences Between C++ and Java?
PDF
No ratings yet
2) What Are The Differences Between C++ and Java?
7 pages
Viva Oopj
PDF
No ratings yet
Viva Oopj
9 pages
Interview Questions 2023 - Java
PDF
No ratings yet
Interview Questions 2023 - Java
7 pages
Tecnical Question
PDF
No ratings yet
Tecnical Question
7 pages
Java Interview-1
PDF
No ratings yet
Java Interview-1
9 pages
OOPS With Java Important Questions For End Sem
PDF
No ratings yet
OOPS With Java Important Questions For End Sem
34 pages
Question: What Is Java?: Click Here
PDF
No ratings yet
Question: What Is Java?: Click Here
32 pages
JAVA-INTERVIEW
PDF
No ratings yet
JAVA-INTERVIEW
12 pages
Java Interview Imp Questions
PDF
No ratings yet
Java Interview Imp Questions
24 pages
150+ Core Java Interview Questions and Answers For Freshers and Experienced in 2023
PDF
No ratings yet
150+ Core Java Interview Questions and Answers For Freshers and Experienced in 2023
69 pages
java basic questions
PDF
No ratings yet
java basic questions
4 pages
Java Interview Questions!!
PDF
No ratings yet
Java Interview Questions!!
16 pages
ASSIGNMENT-questions-course
PDF
No ratings yet
ASSIGNMENT-questions-course
85 pages
Java Interview Questions(1)
PDF
No ratings yet
Java Interview Questions(1)
5 pages
Eswar Java Interview Questions Answers
PDF
No ratings yet
Eswar Java Interview Questions Answers
40 pages
Core Java & Servlet & JSP &JDBC
PDF
No ratings yet
Core Java & Servlet & JSP &JDBC
70 pages
JAVA INTERVIEW QUESTIONS AND THEIR ANSWERS
PDF
No ratings yet
JAVA INTERVIEW QUESTIONS AND THEIR ANSWERS
20 pages
JAVA Short Question Answer
PDF
No ratings yet
JAVA Short Question Answer
9 pages
Reference Questions: Prof. Vaishali Patil, ETRX Dept
PDF
No ratings yet
Reference Questions: Prof. Vaishali Patil, ETRX Dept
6 pages
Java Interview Questions
PDF
No ratings yet
Java Interview Questions
6 pages