WA on test #1 求助

P1184 高手之在一起

我也wa on test1 数据下载下来是对的 不理解 ``` #include<bits/stdc++.h> using namespace std; set<string>qwq; int main(){ int a, b; int ans = 0; cin >> a >> b; for(int i = 0; i <= a; i++){ string s; getline(cin, s); qwq.insert(s); } for (int j = 0; j < b; j++){ string s; getline(cin, s); if (qwq.find(s)!= qwq.end()) ans++; } cout << ans<<endl; return 0; } ```
by optimize2 @ 2022-09-17 19:20:04


test1好像洛谷上最后一个字符串多了一个 `\r`
by william_zy @ 2022-10-06 18:53:27


|