/**
 * 
 */
package pg1;

import java.lang.reflect.Array;

/**
 * @author miguel
 *
 */
public class Grid<T> {
	
	public Grid(int width, int height)
	{
		
	}
	
	
	private Cell<T> [][] _cells;
}

@@ -118,41 +118,760 @@
 lic 
-Grid(int width, int height)%0A%09%7B%0A%09%09
+static char Seperator = ' ';%0A%09%0A%09public Grid(int width, int height, T obj_init)%0A%09%7B%0A%09%09_cells = (Cell%3CT%3E%5B%5D%5B%5D)Array.newInstance( Cell%5B%5D.class, width);%0A%09%09%0A%09%09for (int i = 0; i %3C _cells.length; i++)%0A%09%09%09_cells%5Bi%5D = (Cell%3CT%3E%5B%5D)Array.newInstance(Cell.class, height);%0A%09%09%0A%09%09for (int i = 0; i %3C _cells.length; i++)%0A%09%09%09for (int j = 0; j %3C _cells%5Bi%5D.length; j++)%0A%09%09%09%09_cells%5Bi%5D%5Bj%5D = new Cell%3CT%3E(obj_init);%0A%09%7D%0A%09%0A%09@Override%0A%09public String toString()%0A%09%7B%0A%09%09StringBuilder s = new StringBuilder();%0A%09%09%0A%09%09for (int i = 0; i %3C _cells.length; i++)%0A%09%09%7B%0A%09%09%09for (int j = 0; j %3C _cells%5Bi%5D.length; j++)%0A%09%09%09%7B%0A%09%09%09%09s.append(_cells%5Bi%5D%5Bj%5D.toString());%0A%09%09%09%09if (j != _cells%5Bi%5D.length - 1) s.append(Seperator);%0A%09%09%09%7D%0A%09%09%09if (i != _cells.length - 1) s.append(%22%5Cn%22);%0A%09%09%7D%0A%09%09%0A%09%09return s.toString();
 %0A%09%7D%0A
@@ -899,15 +899,14 @@
 %5B%5D%5B%5D
- 
 _cells;%0A
 %7D%0A
@@ -903,10 +903,145 @@
 _cells;%0A
+%09%0A%09public static void main (String %5B%5D args)%0A%09%7B%0A%09%09Grid%3CCharacter%3E g = new Grid%3CCharacter%3E(10, 10, 'a');%0A%09%09%0A%09%09%0A%09%09System.out.print(g);%0A%09%7D%0A
 %7D%0A

Complete Grid class