Core java Archive

Segment Tree in java

In this post, we will see about Segment Tree in java. Problem Consider an Array of Integers, int arr = {a1, a2, a3, a4, a5,….., an}; Given two types of queries, (i) In the first …

Java add to array

In this post, we will see how to add elements to the array. Using Apache’s common lang library You can use varargs add method to add elements to array dynamically. Here are the few add …

Java FileReader Example

The FileReader class of package provides a seamless and easy-to-use way to read and analyse the contents of a file using Java. The FileReader class, works similar to the FileInputStream class because it reads …

Join Our News Letter - Stay Updated

Subscribe to Awesome Java Content.
You can like our facebook page Java2blog