結果

問題 No.1026 OGAWA's New Keyboard
ユーザー 310icecrystal310icecrystal
提出日時 2023-07-05 06:36:19
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 201 ms / 1,000 ms
コード長 224 bytes
コンパイル時間 305 ms
コンパイル使用メモリ 86,844 KB
実行使用メモリ 87,476 KB
最終ジャッジ日時 2023-09-26 05:42:15
合計ジャッジ時間 4,605 ms
ジャッジサーバーID
(参考情報)
judge13 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 92 ms
71,416 KB
testcase_01 AC 93 ms
71,536 KB
testcase_02 AC 93 ms
71,768 KB
testcase_03 AC 94 ms
71,672 KB
testcase_04 AC 201 ms
81,288 KB
testcase_05 AC 124 ms
77,900 KB
testcase_06 AC 123 ms
77,816 KB
testcase_07 AC 197 ms
87,476 KB
testcase_08 AC 120 ms
77,572 KB
testcase_09 AC 94 ms
71,624 KB
testcase_10 AC 107 ms
76,584 KB
testcase_11 AC 101 ms
72,336 KB
testcase_12 AC 95 ms
71,740 KB
testcase_13 AC 96 ms
71,664 KB
testcase_14 AC 93 ms
71,348 KB
testcase_15 AC 94 ms
71,836 KB
testcase_16 AC 102 ms
72,376 KB
testcase_17 AC 145 ms
79,560 KB
testcase_18 AC 104 ms
76,128 KB
testcase_19 AC 142 ms
79,652 KB
testcase_20 AC 99 ms
71,768 KB
testcase_21 AC 96 ms
71,752 KB
testcase_22 AC 109 ms
72,144 KB
testcase_23 AC 112 ms
76,048 KB
testcase_24 AC 190 ms
84,856 KB
testcase_25 AC 121 ms
77,872 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

N = int(input())

from collections import deque
Deq = deque()
for _ in range(N):
    t,s = map(str,input().split())
    if t == "0":
        Deq.append(s)
    else:
        Deq.appendleft(s)
li = list(Deq)
print("".join(li))
0