use proconio::{fastout, input}; fn yes(yes_no: bool) { if yes_no { println!("Yes"); } else { println!("No"); } } #[fastout] fn main() { input! { k: u32, n: u32, f: u32, a: [u32; f], } let s = a.iter().sum(); let t = k * n; if t >= s { println!("{}", t - s); } else { println!("-1"); } }