• 18 March

    Final keyword in java with example

    In this post, we will see about final keyword in java. Final keyword can be associated with: variable method class Final is often used when you want restrict others from doing any changes. Let’s go through each by one. Final variable If you make any variable final then you are not allowed to change its […]

  • 08 December

    Static keyword in java with examples

    In this post, we will see about static keyword in java.So static keyword can be associated with: Variable Method Block Nested class Lets go through each one by one. Static variable: If any instance variable is declared as static.It is known as static variable. [crayon-614c44d799dfb569077745/] Some points about static variables are: Static variable belongs to […]

  • 17 June

    Method overloading in java

    If two or more methods have same name , but different argument then it is called method overloading. Why you would do that (same name but different argument)? Lets take an example. You want to print salary of employee and sometimes company gives bonus to their employee and sometimes it don’t.So If company don’t give […]

  • 17 June

    Method overriding in java

    If subclass is having same method as base class then it is known as method overriding Or in another words, If subclass provides specific implementation to any method which is present in its one of parents classes then it is known as method overriding Lets start with a real time example: In a small organization,There […]

  • 28 July

    Inheritance in Java

    In this post, we will see about Inheritance in java. It is one of the OOPs principles apart from Abstraction, encapsulation and polymorphism. Introduction The word Inheritance is quite familiar with everyone. In common terms, the word means the bequeathing of property and characteristics from generation to generation. For example, the property or characteristics of […]

  • 27 May

    Polymorphism in java with example

    In this tutorial, we will see about Polymorphism in java. Polymorphism in java is one of core Object oriented programming concepts with Abstraction, encapsulation, and inheritance. Polymorphism means one name many forms. In Java, polymorphism can be achieved by method overloading and method overriding. There are two types of polymorphism in java. Compile time polymorphism. Run […]

  • 02 May

    Encapsulation in java with example

    Encapsulation in java is the process of binding related data(variables) and functionality(methods) into a single unit called class. Encapsulation can be achieved by using access modifier such as public, private, protected or default, so your class will be safe from unauthorized access by others and will be simple to maintain. We can create fully encapsulated […]

  • 27 April

    Abstraction in java

    In this post, we will see about Abstraction in java. Introduction Abstraction is a concept of exposing only essential details and hiding implementation details. It is one of the essential OOPs concept apart from encapsulation, inheritance and polymorphism. Abstraction retains only information which is most relevant for the specific purpose. For example: ArrayList stores objects […]

  • 19 June

    Difference between Abstract Class and Interface in java

    Some of the popular interview questions are “What are differences between abstract class and interface“. “When will you use abstract class and when will you use interface“. So in this article ,we will go through this topic. Before going through differences between them, Lets go through its introduction. Abstract class Abstract classes are created to […]