Here you can find the source of toString(Object[][] arr)
public static String toString(Object[][] arr)
//package com.java2s; //License from project: Open Source License import java.util.Arrays; public class Main { public static String toString(Object[][] arr) { String s = "{"; for (int i = 0; i < arr.length; i++) { if (i == arr.length - 1) s += Arrays.toString(arr[i]); else// w w w. j a va 2 s . c om s += Arrays.toString(arr[i]) + ", "; } s += "}"; return s; } }