use std::collections::HashSet; fn main() { let mut s = String::new(); std::io::stdin().read_line(&mut s).ok(); let n = 10u64.pow(s.trim().parse().unwrap()); let mut h = HashSet::new(); for a in 1..n { if n / a < a { break; } if n % a == 0 { h.insert(a); h.insert(n / a); } } let mut a: Vec<_> = h.iter().collect(); a.sort(); a.iter().for_each(|&x| println!("{}", x)); }