def cardinalityGate(argumentValues,l,h):
  """
    Method that evaluates the CARDINALITY gate
    @ In, argumentValues, list, list of values
    @ In, l, float, min number of allowed events
    @ In, h, float, max number of allowed events
    @ Out, outcome, float, calculated outcome of the gate
  """
  nOcc = argumentValues.count(1)
  if nOcc >= l and nOcc <= h:
    outcome = 1
  else:
    outcome = 0
  return outcome