fn main() { let mut xyz = String::new(); std::io::stdin().read_line(&mut xyz).unwrap(); let v = xyz .split_whitespace() .map(|x| x.parse::().unwrap() % 3 == 0) .any(|x| x); println!("{}", if v { "Yes" } else { "No" }) }