public int Cardinality() { int rtnValue = 0; for (int i = 0; i < array.Length; i++) { if (array[i]) rtnValue += 1; } return rtnValue; }