| # | Time | Username | Problem | Language | Result | Execution time | Memory | 
|---|---|---|---|---|---|---|---|
| 523253 | tato | Sifra (COCI21_sifra) | C++14 | 1 ms | 296 KiB | 
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include <bits/stdc++.h>
#define ll long long
using namespace std;
void answer()
{
	string s;
	cin >> s;
	s += "a";
	
	ll a = 0;
	if('0' < s[0] and s[0] <= '9')
		a = s[0] + 48;
		
	set < ll > st; 
	for(int i = 1; i < s.size(); i++)
		{
			if('0' <= s[i] and s[i] <= '9')
				{
					a *= 10;
					a += (s[i] + 48);
				}
			else
				{
					if('0' <= s[i-1] and s[i-1] <= '9')
						{
							st.insert(a);
							a = 0;
						}
					
				}
		}
	
	cout << st.size();
	
	
}
int main()
{
	int t = 1;
	//cin >> t;
	
	while(t--)
		answer();
	
	return 0;
}
Compilation message (stderr)
| # | Verdict | Execution time | Memory | Grader output | 
|---|---|---|---|---|
| Fetching results... | ||||
