To round the decimal number in java we have DecimalFormat class in java. By using DecimalFormat class format() method we can round double or float number to N... read more ?
How to Sort list of objects by multiple fields in java
Posted by: Instanceofjava Posted date: April 23, 2017 / comment : 0 java Collections interview Questions
In order to compare objects we have comparable and comparator in java. If you want to do custom sorting we will use comparator in java We need to... read more ?
Convert arraylist to array in java with example program
Posted by: Instanceofjava Posted date: March 19, 2017 / comment : 1 Core java Interview Questions , java programming interview questions
Inoder to convert arraylist to array normally we will try to iterate arraylist using loop and get each element and put it in an array. But you know... read more ?
Finalize() method in java with example program
Posted by: Instanceofjava Posted date: March 19, 2017 / comment : 0 Core java Interview Questions
finalize() method pre defined method which is present in java.lang.Object class.finalize() method is protected method defined in java.lang.Object class.The finalize method is a method defined in the Object... read more ?
Final method in java with example programs
Posted by: Instanceofjava Posted date: March 19, 2017 / comment : 1 Core java Interview Questions
If we declare any method as final by placing final keyword then that method becomes final method. The main use of final method in java is they are... read more ?
Format text using printf() method in java
Posted by: Instanceofjava Posted date: March 19, 2017 / comment : 0 Core java Interview Questions
printf method in java: Print() and println() methods are used to print text and object values or format data. In order to format text we also have printf()... read more ?
5 Different ways to print arrays in java
Posted by: Instanceofjava Posted date: March 11, 2017 / comment : 0 arrays
Arrays in java are used to hold similar data types values. System.out.print() method does not print values of array. In order to print array values we have different... read more ?