結果

問題 No.1005 BOT対策
ユーザー gorugo30gorugo30
提出日時 2021-02-25 10:12:16
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 36 ms / 2,000 ms
コード長 167 bytes
コンパイル時間 250 ms
コンパイル使用メモリ 82,384 KB
実行使用メモリ 53,896 KB
最終ジャッジ日時 2025-01-01 20:13:34
合計ジャッジ時間 2,124 ms
ジャッジサーバーID
(参考情報)
judge4 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 28
権限があれば一括ダウンロードができます

ソースコード

diff #

S = input()
T = input()
if len(T) == 1 and T in S:
    print(-1)
elif len(T) > 1 and T.count(T[0]) == len(T):
    print(S.count(T[1:]) - 1)
else:
    print(S.count(T))
0