Subjects

All subjects Django Java Python React Spring Boot JavaScript PHP
Sign Up Free
Java 10 questions

Java Basics and Object-Oriented Programming (OOP)

Learn Java OOP core. Master variables, classes, inheritance, method overriding, interfaces, abstract classes, and encapsulation.

More Java
Interview questions 1–10 of 10
1

What is Java and what are its main features?

Java is a high-level, object-oriented, platform-independent programming language developed by Sun Microsystems...

Read answer →
2

What is the difference between JVM, JDK, and JRE?

ComponentJVM (Java Virtual Machine)JRE (Java Runtime Environment)JDK (Java Development Kit)PurposeExecutes Jav...

Read answer →
3

What are variables and data types in Java?

Variables are named memory locations that store values. Data types define the type of data a variable can hold...

Read answer →
4

What are Object-Oriented Programming (OOP) principles?

OOP is a programming paradigm based on objects and classes. It follows four main principles: Encapsulation, In...

Read answer →
5

What are Classes and Objects in Java?

// Class Definition public class Student { // Attributes (Member Variables) private String name; p...

Read answer →
6

What is Inheritance and how does it work in Java?

Inheritance is a mechanism where a child class inherits properties and methods from a parent class. It promote...

Read answer →
7

What is Polymorphism in Java? Explain Method Overloading and Overriding.

Polymorphism means 'many forms'. In Java, it allows objects to take multiple forms and methods to behave diffe...

Read answer →
8

What is Encapsulation in Java? How do you implement it?

Encapsulation is bundling data (variables) and methods that operate on that data into a single unit (class), a...

Read answer →
9

What is Abstraction in Java? Abstract Classes and Interfaces.

Abstraction is a process of hiding complex implementation details and showing only the essential features. It'...

Read answer →
10

What are Access Modifiers in Java?

Access modifiers control the visibility and accessibility of classes, methods, and variables. Java has four ac...

Read answer →