結果
| 問題 | No.1162 Many Quotients hard |
| ユーザー |
kokatsu
|
| 提出日時 | 2023-01-04 22:05:49 |
| 言語 | D (dmd 2.112.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 2,000 ms |
| コード長 | 179 bytes |
| 記録 | |
| コンパイル時間 | 1,803 ms |
| コンパイル使用メモリ | 187,540 KB |
| 実行使用メモリ | 7,716 KB |
| 最終ジャッジ日時 | 2026-03-06 22:32:57 |
| 合計ジャッジ時間 | 2,660 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 42 |
コンパイルメッセージ
/home/linuxbrew/.linuxbrew/opt/dmd/include/dlang/dmd/core/checkedint.d(814): Warning: cannot inline function `core.checkedint.mulu!().mulu`
ulong mulu()(ulong x, uint y, ref bool overflow)
^
ソースコード
import std;
void main() {
long N;
readf("%d\n", N);
long R = N.to!real.sqrt.floor.to!long;
long res = R * 2;
if (R * (R + 1) > N) --res;
res.writeln;
}
kokatsu