• 28 May

    Constructor in java

    Constructor in java is block of code which allows you to create instance of the object. It does not have return type. It has two main points Constructor name should be same as class Constructor should not have any return type else it will be same as method. There are three types of Constructor in Java. […]

  • 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 […]

  • 27 May

    What is Object and Class In Java?

    Introduction In this post, we will learn about Object and Class in Java. These topics form the core concepts and the building blocks of Object-Oriented Programming for a beginner. As Java is an Object-Oriented Programming language, we design our program and represent/store key entities using Objects and classes. What is Class In Java? A class is a […]

  • 27 May

    Data Types in Java Programming

    Introduction In this article, we will take a look at different Data Types in Java. Data Types form the basic building blocks of one’s guide to learn a programming language. Every programming language provides its own set of Data Types (Generally the Same) with different features and functionalities. Hence, it is important to know about […]

  • 25 May

    Variables In Java Programming

    Introduction In this post, we will look at Variables in Java Programming. It is an essential topic that will provide an insight into how a user stores and handles the data in the computer’s memory to use it efficiently. So, we will cover everything from the definition to the declaration and the different types of […]

  • 24 May

    Access modifiers in java

    The access modifiers in java define accessibility (scope) of variable, method, constructor or class. There are 4 types of access modifiers in java. You don’t have to explicitly put the default modifier.JVM will use default modifier if you do not provide Public, Private and Protected. Public access modifier Public modifier is accessible in the whole […]

  • 22 May

    Super keyword in java

    super Keyword in java is used to refer the object of the immediate superclass, and it is related to inheritance in java. Let’s say you have an instance variable or method of same name in subclass and superclass. How will JVM know which one are you referring to; superclass or subclass? That’s where you can […]

  • 22 May

    this keyword in java with example

    this keyword in java is used to refer to current object or instance of class. It can be used in the constructor to call any other overloaded constructor but this keyword should be the first statement in the constructor. This keyword can be used for instance variables this keyword can be used to refer to the […]

  • 20 May

    Java newFixedThreadPool Example

    In this tutorial, we will learn about Executor’s newFixedThreadPool factory method. In the last tutorial, I have shared an introduction to ThreadPoolExecutor. If you are not aware of concepts of ThreadPoolExecutor, you should go through that first. Executor’s newFixedThreadPool factory method : This method returns ThreadPoolExecutor whose maximum size(let’s say n threads) is fixed.If all […]