题解 | 字符串哈希
字符串哈希
https://www.nowcoder.com/practice/dadbd37fee7c43f0ae407db11b16b4bf
#include <iostream>
#include <string>
#include <set>
using namespace std;
int main() {
set<string> ss;
int n;
string s;
cin>>n;
while(n--){
cin>>s;
ss.insert(s);
};
cout<<ss.size();
}
// 64 位输出请用 printf("%lld")

查看15道真题和解析