結果

問題 No.701 ひとりしりとり
ユーザー JunOnumaJunOnuma
提出日時 2018-06-28 11:04:40
言語 Python2
(2.7.18)
結果
TLE  
実行時間 -
コード長 378 bytes
コンパイル時間 95 ms
コンパイル使用メモリ 6,540 KB
実行使用メモリ 9,444 KB
最終ジャッジ日時 2023-09-13 14:39:14
合計ジャッジ時間 6,068 ms
ジャッジサーバーID
(参考情報)
judge13 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 16 ms
8,684 KB
testcase_01 AC 16 ms
8,848 KB
testcase_02 AC 15 ms
8,848 KB
testcase_03 AC 14 ms
8,700 KB
testcase_04 AC 15 ms
8,696 KB
testcase_05 AC 15 ms
8,840 KB
testcase_06 AC 16 ms
8,860 KB
testcase_07 AC 15 ms
8,684 KB
testcase_08 AC 16 ms
8,876 KB
testcase_09 AC 31 ms
8,996 KB
testcase_10 AC 691 ms
9,444 KB
testcase_11 TLE -
権限があれば一括ダウンロードができます

ソースコード

diff #

import string
import random

def randomString(l):
    return ''.join([random.choice(string.ascii_lowercase) for _ in range(l)])
    
n = int(raw_input())
ls = []
for _ in range(n-1):
    s = randomString(18)
    while s in ls:
        s = randomString(18)
    ls.append(s)
    print "a" + s + "a"
s = randomString(18)
while s in ls:
    s = randomString(18)
print "a" + s + "n"
0