eolymp
bolt
Try our new interface for solving problems
Problems

Owl`s Problem

Owl`s Problem

Everyone knows that the most intelligent one in the woods is Owl. To be the most intelligent one it is necessary to read much, that’s why Owl spend most of its free time with books in the library. Reading one of the most favorite books - "Encyclopedia of problems in mathematics", Owl met this formula: \includegraphics{https://static.e-olymp.com/content/27/27a8790ccc18be63d4f371ce1d5dc36548b4108f.jpg} Inquisitive Owl is very interested with a question, at which the maximum integer \textbf{A} and a integer \textbf{B}, such as \textbf{S}(\textbf{A}) and \textbf{S}(\textbf{B}) are also integer, is going executing the inequality \textbf{S}(A) ≤ \textbf{S}(\textbf{N}) ≤ \textbf{S}(\textbf{B}). \InputFile The first line contains one single number \textbf{N} (\textbf{0} < \textbf{N} ≤ \textbf{2^60}). \OutputFile To put out two required numbers \textbf{A} and \textbf{B} with space, which are corresponded to the inequality.
Time limit 1 second
Memory limit 64 MiB
Input example #1
5
Output example #1
3 8
Author Ruban Nikolaj