結果
問題 | No.1441 MErGe |
ユーザー | da_ab |
提出日時 | 2021-03-27 09:58:12 |
言語 | Python3 (3.12.2 + numpy 1.26.4 + scipy 1.12.0) |
結果 |
TLE
|
実行時間 | - |
コード長 | 358 bytes |
コンパイル時間 | 169 ms |
コンパイル使用メモリ | 12,672 KB |
実行使用メモリ | 53,704 KB |
最終ジャッジ日時 | 2024-05-06 21:49:47 |
合計ジャッジ時間 | 9,109 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge4 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 447 ms
49,568 KB |
testcase_01 | AC | 445 ms
43,824 KB |
testcase_02 | AC | 444 ms
44,332 KB |
testcase_03 | AC | 498 ms
44,060 KB |
testcase_04 | AC | 521 ms
43,944 KB |
testcase_05 | AC | 860 ms
43,808 KB |
testcase_06 | AC | 904 ms
43,944 KB |
testcase_07 | AC | 953 ms
44,064 KB |
testcase_08 | TLE | - |
testcase_09 | -- | - |
testcase_10 | -- | - |
testcase_11 | -- | - |
testcase_12 | -- | - |
testcase_13 | -- | - |
testcase_14 | -- | - |
testcase_15 | -- | - |
testcase_16 | -- | - |
testcase_17 | -- | - |
testcase_18 | -- | - |
testcase_19 | -- | - |
testcase_20 | -- | - |
testcase_21 | -- | - |
testcase_22 | -- | - |
testcase_23 | -- | - |
testcase_24 | -- | - |
testcase_25 | -- | - |
testcase_26 | -- | - |
testcase_27 | -- | - |
testcase_28 | -- | - |
testcase_29 | -- | - |
ソースコード
# 1441 : MErGe import numpy as np from sys import stdin N,Q=list(map(int,stdin.readline().split())) A=np.array(list(map(int,stdin.readline().split()))) for _ in range(Q): T,l,r=list(map(int,stdin.readline().split())) l-=1 r-=1 if T==1: A=np.append(np.append(A[0:l],[sum(A[l:r+1])]),A[r+1:]) else: print(sum(A[l:r+1]))