public int countRoots(int[] a) {

		int count = 0;
		for (int x = 0; x < 2; x++) {
			int total = a[0];

			for (int i = 1; i < a.length; i++) {
				if (x == 1 && a[i] == 1) {
					total++;
				}

			}
			if (total % 2 == 0) {
				count++;
			}
		}
		return count;
	}