結果

問題 No.1764 Square
ユーザー titan23titan23
提出日時 2022-04-01 18:52:18
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 47 ms / 2,000 ms
コード長 309 bytes
コンパイル時間 233 ms
コンパイル使用メモリ 82,432 KB
実行使用メモリ 53,632 KB
最終ジャッジ日時 2024-04-30 02:59:23
合計ジャッジ時間 1,235 ms
ジャッジサーバーID
(参考情報)
judge5 / judge2
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 46 ms
53,632 KB
testcase_01 AC 45 ms
53,376 KB
testcase_02 AC 46 ms
53,376 KB
testcase_03 AC 47 ms
53,376 KB
testcase_04 AC 46 ms
53,632 KB
testcase_05 AC 46 ms
53,504 KB
testcase_06 AC 46 ms
53,504 KB
testcase_07 AC 47 ms
53,504 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
input = lambda: sys.stdin.readline().rstrip()
from collections import deque

##################

k = int(input())

q = [deque(['A','E']), deque(['B']), deque(['C']), deque(['D'])]

for i in range(k):
  v = q[i%4].popleft()
  q[(i+1)%4].append(v)

for i in range(4):
  print(''.join(map(str, q[i])))
0