public void printNodesByLevel(ArrayList<ArrayList<Integer>> levelNodes) {
		if (levelNodes == null)
			return;

		System.out.println("[");
		for (int i = 0; i < levelNodes.size(); i++) { // each level
			System.out.print("[");
			for (int j = 0; j < levelNodes.get(i).size(); j++) {
				if (j == 0)
					System.out.print(levelNodes.get(i).get(j));
				else
					System.out.print("," + levelNodes.get(i).get(j));
			}

			if (i == levelNodes.size())
				System.out.println("]");
			else
				System.out.println("],");
		}
		System.out.println("]");
	}