結果

問題 No.345 最小チワワ問題
ユーザー FVyagwD8
提出日時 2023-02-26 19:23:25
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
WA  
実行時間 -
コード長 336 bytes
コンパイル時間 102 ms
コンパイル使用メモリ 12,544 KB
実行使用メモリ 10,496 KB
最終ジャッジ日時 2024-09-14 08:41:26
合計ジャッジ時間 2,094 ms
ジャッジサーバーID
(参考情報)
judge3 / judge2
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample WA * 3
other AC * 14 WA * 15
権限があれば一括ダウンロードができます

ソースコード

diff #

S = input()
count_len = 0
count_cww = 0
cww_num   = -1
for i in S:
    if count_cww == 3:
        cww_num = count_len
        break
    if count_cww >= 1:
        if i == "w":
            count_cww += 1
            count_len += 1
            continue
    if i == "c":
            count_cww += 1
            count_len += 1
print(cww_num)
0