Latest Posts

Why String is Immutable in Java?

Why String is immutable in Java is one of the popular interview questions. The string is one of the most used classes in any programming language. We know that String is immutable and final in….

What is Java String Pool?

As the name suggests, String Pool in java is a pool of Strings stored in Java Heap Memory. We know that String is special class in java and we can create String object using new….

String to char array java – convert string to char

Sometimes we have to convert String to the character array in java programs or convert a string to char from specific index. String to char Java String class has three methods related to char. Let’s….

Java String split

Java String split() method is used to split the string into a string array based on the provided regular expression. Java String split Sometimes we have to split String in Java, for example splitting data….

How to Sort a List in Java

Sometimes we have to sort a list in Java before processing its elements. In this tutorial, we will learn how to sort a list in the natural order. We will also learn how to use….

How to Sort an Array in Java

Java Array is like a container that can hold a fixed number of the same type of items, it can be primitive types as well as Objects. Array Sorting in Java Sometimes we need to….

Comparable and Comparator in Java Example

Comparable and Comparator in Java are very useful for sorting the collection of objects. Java provides some inbuilt methods to sort primitive types array or Wrapper classes array or list. Here we will first learn….

How to Convert String to Array in Java

Sometimes we have to split String to array based on delimiters or some regular expression. For example, reading a CSV file line and parsing them to get all the data to a String array. In….

Java String Array to String

Today we will look into how to convert Java String array to String. Sometimes we have to convert String array to String for specific requirements. For example; we want to log the array contents or….

String to byte array, byte array to String in Java

Today we will learn how to convert String to byte array in java. We will also learn how to convert byte array to String in Java. String to byte array We can use String class….

close
Generic selectors
Exact matches only
Search in title
Search in content
Search in posts
Search in pages