题解 | #字符个数统计#
字符个数统计
https://www.nowcoder.com/practice/eb94f6a5b2ba49c6ac72d40b5ce95f50
//https://www.nowcoder.com/practice/eb94f6a5b2ba49c6ac72d40b5ce95f50?tpId=37&tqId=21233&rp=1&ru=/exam/oj/ta&qru=/exam/oj/ta&sourceUrl=%2Fexam%2Foj%2Fta%3FtpId%3D37&difficulty=undefined&judgeStatus=undefined&tags=&title= #include <iostream> #include <set> using namespace std; int main() { string s; while (cin >> s) { set<char> clist; for(auto c:s){ if(0<=c&&c<=127) clist.insert(c); } cout << clist.size(); } }