結果
| 問題 |
No.1005 BOT対策
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2022-08-02 10:05:48 |
| 言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 295 bytes |
| コンパイル時間 | 1,635 ms |
| コンパイル使用メモリ | 167,340 KB |
| 実行使用メモリ | 6,948 KB |
| 最終ジャッジ日時 | 2024-07-23 02:59:19 |
| 合計ジャッジ時間 | 2,760 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 19 WA * 8 |
ソースコード
#include<bits/stdc++.h>
using namespace std;
int main(){
string s, t;
cin >> s >> t;
int ans = 0;
for(int i = 0; i + t.size() <= s.size();){
if(s.substr(i, t.size()) == t){
ans++;
i += t.size();
}else i++;
}
cout << ans << endl;
}