Java Lambda : Beginners Guide
This article explains Java Lambda expressions in Java 8. You can find complete code here.
This article explains Java Lambda expressions in Java 8. You can find complete code here.
Java HashMap is a HashTable based implementation of Map. This is the reason why the interviewer always asks for the difference between HashMap and HashTable. HashMap is mostly equated to HashTable except below two differences. HashMap is unsynchronized while HashTable…
What is this this is a keyword in Java. It can be used inside the method or constructor of a class. It(this) works as a reference to the current object, whose method or constructor is being invoked. This keyword can refer…
In this article, we will learn about the order of execution of blocks in Java. Different blocks and their order of execution in Java Class Static Block Init Block(Anonymous Block) Constructor /* * Here we will learn to see how the…
In Java, JVM (Java Virtual Machine) will always look for a specific method signature to start running an application, and that would be the public static void main (String args[]). The main() method represents the entry point of Java programs,…
Here we will discuss some basics topics related to Java. Where to download Java. How to install Java. Setting up the Environment Variables. Our First Java Program. How to compile a Java application. How to run a Java Application. In next…
In order to understand JDK vs JRE vs JVM. You need to first understand each and every term. So let’s start by defining JDK (Java Development Kit), JRE (Java Runtime Environment), and JVM (Java Virtual Machine).
Generally finally block is used to close all the resources (viz., file, database connection, socket or anything that should be closed after its task is done) to prevent any leaks. Sample code: public class ResourceMgt { public static void main(String[]…
As developers, we deal with risky situations on a daily basis. Server goes down, or there isn’t enough space to allocate objects on the heap or file is not present in the given location and so on. So every time…
Thread term can be used in two ways An instance of class java.lang.Thread A Thread of Execution