結果

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

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 16 ms
8,792 KB
testcase_01 AC 17 ms
8,860 KB
testcase_02 AC 17 ms
8,744 KB
testcase_03 AC 16 ms
8,820 KB
testcase_04 AC 15 ms
8,752 KB
testcase_05 AC 15 ms
8,780 KB
testcase_06 AC 15 ms
8,868 KB
testcase_07 AC 16 ms
8,880 KB
testcase_08 AC 15 ms
8,772 KB
testcase_09 AC 27 ms
8,864 KB
testcase_10 AC 653 ms
9,328 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(10)
    while s in ls:
        s = randomString(10)
    ls.append(s)
    print "a" + s + "a"
s = randomString(10)
while s in ls:
    s = randomString(10)
print "a" + s + "n"
0