Home » Archives for Vipul Kumar

Author Archives: Vipul Kumar

Vipul Kumar
Vipul is a Senior Software Engineer with experience in different software technologies including Java, Javascript, Angular, React, Material Design, databases (MySQL), HTML/CSS and even AWS, Big Data and Machine Learning. He likes learning new technologies and using the latest libraries in his work.

Java Stack Example

In this post, we feature a comprehensive Java Stack Example. 1. Introduction A stack is a container of objects that are inserted and removed according to the last-in-first-out (LIFO) principle. In the stacks, only two operations are allowed-  push the item into the stackpop the item out of the stack. A stack is a limited access data structure. Elements can be added ...

Read More »

Initialize Array Java Example

In this article, we are going to see the initialize array Java Example. We will cover the following things in this article: What are Arrays in Java?Array TypeArray ElementsCreating an array variableAccessing array ElementsInitialize array Java Example 1. What are Arrays in Java In java programming language arrays are objects.Arrays can contain empty, one or more than one element in ...

Read More »

Java .class File Example

In this post, we feature a comprehensive article on Java .class File. Have you ever wondered: What is bytecode in Java? What makes Java a platform-independent language? What is the Java .class file?Structure of Java class file. In this article, we will address all the above questions and we will deep dive into understanding bytecode or .class file in Java ...

Read More »

Java Thread sleep Example

In this article we are going to get an in depth understanding of: What is a thread in java?What is the use of sleep() in java thread based execution?Important points to remember while using Thread.sleep().How Thread.sleep() works. 1. What is a thread in Java Lets start with what the thread exactly is and how it is supported in Java. Thread ...

Read More »

Java List Example

1. List Interface In this post, we feature a comprehensive article on Java List. We are going to check in depth the java.lang.List in java. 2. List in Collection Hierarchy There are four concrete implementation classes in for List interface in java. List interface extends the Collection interface for some common operation to be supported by all implementation classes with ...

Read More »

Java Round Number to N Decimal Places Example

In this example, we are going to show how we can round a decimal number in Java. Before going in details let us brief you about what exactly is the rounding a number means. 1. What is rounded Number A rounded number has about the same value as the original number we started with. It is less exact than the ...

Read More »

Calculate square root in Java with Math sqrt

This is an example of how to calculate the square root in Java, using the sqrt(double a) method of Math Class. The class Math contains methods for performing basic numeric operations such as the elementary exponential, logarithm, square root, and trigonometric functions. Calculating the square root of a number implies that you should: Use the sqrt(double a) method of Math Class. The method gets a double ...

Read More »

Java Generics Examples

1. Introduction Sun Microsystems included Java Generics in java 1.5 to introduce the type-safety feature while using the collection classes. It also complements auto-boxing, auto-unboxing, bounded variables, covariance, etc. There are other benefits of Generics. We will uncover each. 2. What is Java Generics Java Generics is a technical term denoting a set of language features related to the definition and ...

Read More »