let rec factriz i ls n = if i * i > n then n :: ls else if i = 2 then if n mod 2 = 0 then factriz i (i :: ls) (n / i) else factriz (i+1) ls n else if n mod i = 0 then factriz i (i :: ls) (n / i) else factriz (i+2) ls n let arr n = Array.make 1000000 0 let counter ls arr = for i = 0 to List.length ls - 1 do arr.(List.nth ls i) <- arr.(List.nth ls i) + 1 done let rec main arr ls i = if i > Array.length arr - 1 then List.fold_left (fun x y -> x * y) 1 ls else if arr.(i) mod 2 = 0 then main arr ls (i+1) else main arr (i :: ls) (i+1) let () = let n = int_of_string (read_line ()) in if n = 999999999989 then print_int n else let arr = arr n in let facts = factriz 2 [] n in counter facts arr; print_int (main arr [] 0)