結果

問題 No.342 一番ワロタww
ユーザー naimonon77
提出日時 2019-02-01 12:27:46
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
RE  
実行時間 -
コード長 518 bytes
コンパイル時間 111 ms
コンパイル使用メモリ 12,416 KB
実行使用メモリ 11,136 KB
最終ジャッジ日時 2024-11-21 21:55:18
合計ジャッジ時間 1,459 ms
ジャッジサーバーID
(参考情報)
judge2 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 12 WA * 1 RE * 1
権限があれば一括ダウンロードができます

ソースコード

diff #

import random
import time
import copy
import io, sys

s = input()

list1 = []
buf = []
cnt = 0
for c in s:
    if (c == 'w'): cnt += 1 
    elif (c != 'w' and cnt != 0):
        list1.append((''.join(buf), cnt))
        buf = [c]
        cnt = 0
    else: buf.append(c)
if (cnt != 1):
    list1.append((''.join(buf), cnt))

list1.sort(key=lambda t:t[1], reverse=True)

#print(list1)
if (list1[0][1] > 0):
    for t in list1:
        if (t[1] != list1[0][1]):
            break
        if (t[0] != ""): print(t[0])
0