use std::io; fn main(){ let mut s = String::new(); io::stdin().read_line(&mut s).ok(); let r = s.trim().chars().fold(0, |n , m| n + (m as i32 - 48)); print!("{:#?}",r); }