Java Coder
Comparing arrays not working correctly?
2 Answer(s)      a year and 5 months ago
Posted in : Java Beginners

Comparing arrays not working correctly?

Advertisement
View Answers

December 23, 2013 at 5:38 PM


Here is how you can Compare two char array in java



December 23, 2013 at 5:40 PM


You can try:

Arrays.equals(); // <---- One Dimensional Arrays

or 
ArrayUtils.isEquals(); // <---- Multi Dimensional Arrays

The forgoing Array methods can be used to compare the contents of the two arrays.