結果
| 問題 |
No.1700 floor X
|
| コンテスト | |
| ユーザー |
abc
|
| 提出日時 | 2021-10-22 14:11:56 |
| 言語 | Ruby (3.4.1) |
| 結果 |
AC
|
| 実行時間 | 268 ms / 2,000 ms |
| コード長 | 176 bytes |
| コンパイル時間 | 383 ms |
| コンパイル使用メモリ | 7,424 KB |
| 実行使用メモリ | 12,544 KB |
| 最終ジャッジ日時 | 2024-07-03 10:46:28 |
| 合計ジャッジ時間 | 13,255 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 1 |
| other | AC * 44 |
コンパイルメッセージ
Main.rb:10: warning: mismatched indentations at 'else' with 'if' at 8 Main.rb:11: warning: mismatched indentations at 'end' with 'else' at 10 Syntax OK
ソースコード
t = gets.to_i t.times do n = gets.to_i l = 0 r = 1e20 while (r - l > 1) do mid = (l + r).div(2) if (mid * mid <= n) then l = mid else r = mid end end p l end
abc