Java tutorial
import java.util.Arrays; public class Main { public static void main(String[] args) { float[] arr1 = new float[] { 1f, 123f }; float[] arr2 = new float[] { 1f, 123f, 22f, 4f }; float[] arr3 = new float[] { 1f, 123f }; System.out.println(Arrays.equals(arr1, arr2)); System.out.println(Arrays.equals(arr1, arr3)); } }