use std::io::*; fn main() { let mut s: String = String::new(); std::io::stdin().read_to_string(&mut s).ok(); let mut itr = s.trim().split_whitespace(); let mut n: u64 = itr.next().unwrap().parse().unwrap(); let mut i = 2; let mut u = 1; let mut ans = 1; while i * i <= n { if n % i == 0 { let mut cnt = 0; while n % i == 0 { cnt += 1; n /= i; } if cnt % 2 == 1 { ans *= i; } for _ in 0..cnt / 2 { u *= i; } } i += 1; } if n != 1 { ans *= n; } println!("{} {}", u, ans); }