I want to sort an Object[][] by the first column which consists of ints.
Take, for example, this array:
Object[][] array = {{1, false, false}, {2, true, false}, {0, true, true}};
Now, I want to create a new array whose rows are sorted in a way that the first element of each row ascends:
Object[][] newArray = ...;
System.out.println(Arrays.deepToString(newArray));
What it should print: {{0, true, true}, {1, false, false}, {2, true, false}}
Thank you.