結果

問題 No.2721 "Don't say N" Game
ユーザー MasKoaTSMasKoaTS
提出日時 2023-10-05 22:35:51
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 79 ms / 2,000 ms
コード長 214 bytes
コンパイル時間 377 ms
コンパイル使用メモリ 87,452 KB
実行使用メモリ 75,636 KB
最終ジャッジ日時 2023-10-05 22:35:53
合計ジャッジ時間 1,587 ms
ジャッジサーバーID
(参考情報)
judge14 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 71 ms
71,500 KB
testcase_01 AC 77 ms
75,344 KB
testcase_02 AC 76 ms
75,636 KB
testcase_03 AC 78 ms
75,144 KB
testcase_04 AC 72 ms
71,216 KB
testcase_05 AC 79 ms
75,444 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
input = sys.stdin.readline


query = [int(input()) for _ in [0] * int(input())]

st = set([i ** 2 for i in range(1, 32)])
for n in query:
    if(n in st):
        print('P')
    else:
        print('K')
0