제출 #375107

#제출 시각아이디문제언어결과실행 시간메모리
375107SeDunionSifra (COCI21_sifra)C++17
50 / 50
1 ms388 KiB
#include<bits/stdc++.h> using namespace std; using ll = long long; const int N = 1e6 + 66; int main() { ios_base::sync_with_stdio(0); cin.tie(0), cout.tie(0); string s; cin >> s; set<string>st; string cur = ""; for (char c : s) { if (isdigit(c)) { cur += c; } else if (!cur.empty()) { st.insert(cur); cur = ""; } } if (!cur.empty()) { st.insert(cur); } cout << st.size(); }
#Verdict Execution timeMemoryGrader output
Fetching results...