結果
| 問題 | No.1700 floor X |
| コンテスト | |
| ユーザー |
Kiri8128
|
| 提出日時 | 2021-10-08 21:51:34 |
| 言語 | PyPy3 (7.3.17) |
| 結果 |
AC
|
| 実行時間 | 101 ms / 2,000 ms |
| コード長 | 242 bytes |
| 記録 | |
| コンパイル時間 | 183 ms |
| コンパイル使用メモリ | 85,504 KB |
| 実行使用メモリ | 81,496 KB |
| 最終ジャッジ日時 | 2026-03-24 18:32:12 |
| 合計ジャッジ時間 | 5,150 ms |
|
ジャッジサーバーID (参考情報) |
judge2_0 / judge3_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 1 |
| other | AC * 44 |
ソースコード
def sqrt(n):
if n == 0: return 0
x = 1 << (n.bit_length() + 1) // 2
y = (x + n // x) // 2
while y < x:
x = y
y = (x + n // x) // 2
return x
T = int(input())
for _ in range(T):
print(sqrt(int(input())))
Kiri8128