use std::io::Read; fn main() { let mut s = String::new(); std::io::stdin().read_to_string(&mut s).ok(); let mut itr = s.trim().split_whitespace(); let n: i32 = itr.next().unwrap().parse().unwrap(); let a: Vec = itr.map(|e| e.parse().unwrap()).collect(); let s: i32 = a.iter().sum(); let ans = (0..100).filter(|&i| (s + i) % n == 0).count(); println!("{}", ans); }