Submission #12066


ソースコード

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#include <bits/stdc++.h>
using namespace std;
#define int long long
#define rep(i, n) for(int i = 0; i < (n); i++)
#define trep(i, n) for(int i = 0; i <= (n); i++)
#define mfor(i, s, t) for(int i = (s); i < (t); i++)
#define tfor(i, s, t) for(int i = (s); i <= (t); i++)
signed main() {
int n;
string s;
cin >> n >> s;
cin.ignore();
int ans = 0;
rep(i, n) {
string w;
getline(cin, w);
stringstream ss(w);
while(ss >> w, ss.good()) {
if(w == s) {
ans++;
}
}
}
cout << ans << endl;
}

ステータス

項目 データ
問題 0003 - 聖書
ユーザー名 gotoloop
投稿日時 2017-01-25 19:27:57
言語 C++11
状態 Accepted
得点 5
ソースコード長 571 Byte
最大実行時間 36 ms
最大メモリ使用量 580 KB

セット

セット 得点 Cases
1 ALL 3 / 3 *
2 SUB1 1 / 1 Alice_in1.txt
3 SUB2 1 / 1 Alice_in2.txt

テストケース

ファイル名 状態 実行時間 メモリ使用量 #
Alice_in1.txt AC 32 ms 476 KB
1
2
Alice_in2.txt AC 21 ms 580 KB
1
3
Alice_in3.txt AC 36 ms 560 KB
1