/**
     * Creates a 2D array of the given width and height, filled with entirely with the value contents.
     * You may want to use {@link #fill(char[][], char)} to modify an existing 2D array instead.
     * @param contents the value to fill the array with
     * @param width    the desired width
     * @param height   the desired height
     * @return a freshly allocated 2D array of the requested dimensions, filled entirely with contents
     */
public static char[][] fill(char contents, int width, int height) {
        char[][] next = new char[width][height];
        for (int x = 0; x < width; x++) {
            Arrays.fill(next[x], contents);
        }
        return next;
    }
public static char[][] fill(char contents, int width, int height) {
char[][] next = new char[width][height];
for (int x = 0; x < width; x++) {
Arrays.fill(next[x], contents);
}
return next;
}
public static char[][] fill(char contents, int width, int height) {
char[][] next = new char[width][height];
for (int x = 0; x < width; x++) {
Arrays.fill(next[x], contents);
}
return next;
}
public static char[][] fill(char contents, int width, int height) {
char[][] next = new char[width][height];
for (int x = 0; x < width; x++) {
Arrays.fill(next[x], contents);
}
return next;
}