Courses
Tutorials
Practice
Data Structure
Java
Python
HTML
Interview Preparation
DSA
Practice Problems
C
C++
Java
Python
JavaScript
Data Science
Machine Learning
Courses
Linux
DevOps
SQL
Web Development
System Design
Aptitude
GfG Premium
Similar Topics
Web Technologies
37.4K+ articles
Java
10.8K+ articles
Java Programs
2.0K+ articles
Computer Science Fundamentals
1.5K+ articles
java-interfaces
78+ articles
Java-Object Oriented
59+ articles
Java-Constructors
36+ articles
Java-Packages
17+ articles
java-overriding
16+ articles
Inheritance
9+ articles
java-inheritance
35 posts
Recent Articles
Popular Articles
Class Type Casting in Java
Last Updated: 17 September 2021
Typecasting is the assessment of the value of one primitive data type to another type. In java, there are two types of casting namely upcasting and downcasting as follows:...
read more
Java
Java Programs
Java-Object Oriented
java-inheritance
What is Has-A-Relation in Java?
Last Updated: 16 September 2024
Association is the relation between two separate classes which establishes through their Objects. Composition and Aggregation are the two forms of association. In Java, a ...
read more
Java
Java-Object Oriented
java-inheritance
Different Ways to Prevent Method Overriding in Java
Last Updated: 10 August 2021
Inheritance is a substantial rule of any Object-Oriented Programming (OOP) language but still, there are ways to prevent method overriding in child classes which are as fo...
read more
Java
Picked
Java-Object Oriented
java-inheritance
Java Program to Use Method Overriding in Inheritance for Subclasses
Last Updated: 28 January 2021
Method overriding in Java is when a subclass implements a method that is already present inside the superclass. With the help of method overriding we can achieve runtime p...
read more
Java
Java Programs
Picked
Java-Object Oriented
java-inheritance
Favoring Composition Over Inheritance In Java With Examples
Last Updated: 17 March 2025
In object-oriented programming (OOP), choosing between inheritance and composition is crucial for designing flexible and maintainable code. This article explores why you s...
read more
Java
Picked
Java-Object Oriented
java-inheritance
Resolving Conflicts During Multiple Inheritance in Java
Last Updated: 30 November 2021
A class can implement multiple interfaces in java, but what if the implemented multiple default interfaces have default methods with the same signatures? Then in the imple...
read more
Java
Picked
java-inheritance
What is the Need of Inheritance in Java?
Last Updated: 17 March 2021
Inheritance, as we have all heard is one of the most important features of Object-Oriented Programming Languages whether it is Java, C++, or any other OOP language. But wh...
read more
Java
Java-Object Oriented
java-inheritance
Variables in Java Do Not Follow Polymorphism and Overriding
Last Updated: 23 September 2021
Variables in Java do not follow polymorphism. Overriding is only applicable to methods but not to variables. In Java, if the child and parent class both have a variable wi...
read more
Java
Blogathon
Blogathon-2021
java-inheritance
java-overriding
Java - Exception Handling With Constructors in Inheritance
Last Updated: 15 November 2021
Java provides a mechanism to handle exceptions. To learn about exception handling, you can refer to exceptions in java. In this article, we discuss exception handling with...
read more
Java
Blogathon
Blogathon-2021
Java-Object Oriented
java-inheritance
Java-Exception Handling
What is Is-A-Relationship in Java?
Last Updated: 01 December 2021
A relationship in Java means different relations between two or more classes. For example, if a class Bulb inherits another class Device, then we can say that Bulb is havi...
read more
Java
Picked
java-inheritance
Java Program to Calculate Interest For FDs, RDs using Inheritance
Last Updated: 23 May 2022
Inheritance is an important pillar of OOP(Object-Oriented Programming). It is the mechanism in java by which one class is allowed to inherit the features(fields and method...
read more
Java
Java Programs
Geeks Premier League
Geeks-Premier-League-2022
java-inheritance
Static Control Flow with Inherited Classes in Java
Last Updated: 16 February 2023
Before understanding the static control flow of a program, we must be familiar with the following two terms:Class loading: It refers to reading the .class file and loading...
read more
Java
java-inheritance
How to Implement Multiple Inheritance by Using Interfaces in Java?
Last Updated: 08 April 2023
Multiple Inheritance is a feature of an object-oriented concept, where a class can inherit properties of more than one parent class. The problem occurs when methods with t...
read more
Java
java-inheritance
java-interfaces
Diamond Problem in Java
Last Updated: 22 September 2023
Diamond Problem is a problem faced during Multiple Inheritance in Java. Let's see what is Diamond Problem and how to solve this problem.What is a Diamond Problem in Java?I...
read more
Java
Java-Object Oriented
java-inheritance
Why Java doesn't support Multiple Inheritance?
Last Updated: 20 March 2024
Multiple Inheritance is a feature provided by OOPS, it helps us to create a class that can inherit the properties from more than one parent. Some of the programming langua...
read more
Java
Java-Object Oriented
java-inheritance
Inheritance
1
2
3
We use cookies to ensure you have the best browsing experience on our website. By using our site, you acknowledge that you have read and understood our
Cookie Policy
&
Privacy Policy
Got It !