結果

問題 No.3072 Sum of sqrt(x)
ユーザー maspymaspy
提出日時 2020-06-21 03:12:18
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
WA  
実行時間 -
コード長 358 bytes
コンパイル時間 921 ms
コンパイル使用メモリ 10,636 KB
実行使用メモリ 188,616 KB
最終ジャッジ日時 2023-09-11 23:11:54
合計ジャッジ時間 121,606 ms
ジャッジサーバーID
(参考情報)
judge14 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 145 ms
29,436 KB
testcase_01 AC 131 ms
29,368 KB
testcase_02 AC 131 ms
29,360 KB
testcase_03 AC 133 ms
29,448 KB
testcase_04 AC 132 ms
29,320 KB
testcase_05 AC 129 ms
29,336 KB
testcase_06 AC 132 ms
29,416 KB
testcase_07 WA -
testcase_08 AC 563 ms
170,796 KB
testcase_09 AC 700 ms
170,664 KB
testcase_10 AC 1,082 ms
188,224 KB
testcase_11 AC 1,492 ms
188,200 KB
testcase_12 TLE -
testcase_13 AC 1,965 ms
186,532 KB
testcase_14 AC 1,989 ms
188,428 KB
testcase_15 AC 1,982 ms
186,404 KB
testcase_16 TLE -
testcase_17 AC 1,813 ms
186,872 KB
testcase_18 AC 1,881 ms
186,224 KB
testcase_19 AC 1,916 ms
186,572 KB
testcase_20 AC 1,882 ms
186,300 KB
testcase_21 AC 1,835 ms
186,160 KB
testcase_22 AC 1,845 ms
186,380 KB
testcase_23 TLE -
testcase_24 TLE -
testcase_25 AC 1,810 ms
186,640 KB
testcase_26 AC 1,864 ms
186,420 KB
testcase_27 AC 1,420 ms
186,432 KB
testcase_28 WA -
testcase_29 AC 1,705 ms
186,500 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
import numpy as np

read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

nums = np.array(read().split(), np.float64)[1:]
np.sqrt(nums, out=nums)

K = 1<<10
high, low = np.divmod(nums, K)
np.cumsum(high, out=high)
np.cumsum(low, out=low)
x = high * K + low
print('\n'.join(map(str, x.tolist())))
0