1638 | 2022-11-30 21:31:22 | Timi | Kvázi-Izogram | cpp11 | Accepted 100/100 | 61ms | 4328 KiB |
#include <iostream>
#include <string>
#include <cctype>
#include <map>
using namespace std;
int main()
{
int n, db=0;
string s;
map<char, int> betuk;
cin>>n;
cin.get();
for (int i=0; i<n; i++)
{
getline(cin,s);
for (int j=0; j<s.size(); j++)
{
if ((tolower(s[j])>='a')&&(tolower(s[j])<='z'))
betuk[tolower(s[j])]++;
}
int ok=0;
for (auto it : betuk)
if (it.second>2)
ok++;
if (ok==0)
db++;
betuk.clear();
}
cout<<db;
return 0;
}
Subtask | Sum | Test | Verdict | Time | Memory | ||
---|---|---|---|---|---|---|---|
subtask1 | 0/0 | ||||||
1 | Accepted | 3ms | 1812 KiB | ||||
2 | Accepted | 2ms | 2004 KiB | ||||
subtask2 | 30/30 | ||||||
3 | Accepted | 2ms | 2208 KiB | ||||
4 | Accepted | 2ms | 2452 KiB | ||||
5 | Accepted | 2ms | 2560 KiB | ||||
6 | Accepted | 2ms | 2692 KiB | ||||
7 | Accepted | 4ms | 2728 KiB | ||||
subtask3 | 50/50 | ||||||
8 | Accepted | 2ms | 2820 KiB | ||||
9 | Accepted | 3ms | 3024 KiB | ||||
10 | Accepted | 3ms | 3224 KiB | ||||
11 | Accepted | 3ms | 3432 KiB | ||||
12 | Accepted | 3ms | 3512 KiB | ||||
13 | Accepted | 3ms | 3616 KiB | ||||
subtask4 | 20/20 | ||||||
14 | Accepted | 4ms | 3504 KiB | ||||
15 | Accepted | 8ms | 3912 KiB | ||||
16 | Accepted | 14ms | 3860 KiB | ||||
17 | Accepted | 26ms | 3980 KiB | ||||
18 | Accepted | 43ms | 3996 KiB | ||||
19 | Accepted | 54ms | 4084 KiB | ||||
20 | Accepted | 61ms | 4328 KiB |