fn multiple_of_any(min: u64, max: u64, multiple_predicates: &[u64]) -> u64 {
  (min..max)
    .filter(|n| multiple_predicates.iter().any(|p| n % p == 0))
    .sum()
}

fn main() {
  println!("{}", multiple_of_any(0, 1000, &[3, 5]))
}

