diff options
Diffstat (limited to 'others/volume1/027.pas')
-rw-r--r-- | others/volume1/027.pas | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/others/volume1/027.pas b/others/volume1/027.pas new file mode 100644 index 0000000..0b285bd --- /dev/null +++ b/others/volume1/027.pas @@ -0,0 +1,16 @@ +uses cmath; + +var + n: int64; + m: int32; + +begin + readln(n); + m := trunc(sqrt(n)); + if issquare(n) then + writeln(m, ' ', m) + else if n > m * (m + 1) then + writeln(m + 1, ' ', m + 1) + else + writeln(m, ' ', m + 1) +end. |