public int getCount(int x) {
		int count = 0;
		for (int row = 0; row < matrix.length; row++) {
			for (int col = 0; col < matrix[0].length; col++) {
				if (matrix[row][col] == x) {
					count++;
				}
			}
		}
		return count;
	}