Task: | trener |
Sender: | Hansuzu |
Submission time: | 2016-07-27 14:03:38 +0300 |
Language: | C++ |
Status: | READY |
Result: | 100 |
group | verdict | score |
---|---|---|
#1 | ACCEPTED | 100 |
test | verdict | time | |
---|---|---|---|
#1 | ACCEPTED | 0.05 s | details |
#2 | ACCEPTED | 0.05 s | details |
#3 | ACCEPTED | 0.05 s | details |
#4 | ACCEPTED | 0.05 s | details |
#5 | ACCEPTED | 0.05 s | details |
#6 | ACCEPTED | 0.05 s | details |
#7 | ACCEPTED | 0.05 s | details |
#8 | ACCEPTED | 0.05 s | details |
#9 | ACCEPTED | 0.05 s | details |
#10 | ACCEPTED | 0.05 s | details |
#11 | ACCEPTED | 0.05 s | details |
#12 | ACCEPTED | 0.06 s | details |
#13 | ACCEPTED | 0.06 s | details |
#14 | ACCEPTED | 0.05 s | details |
#15 | ACCEPTED | 0.06 s | details |
Compiler report
input/code.cpp: In function 'int main()': input/code.cpp:12:13: warning: array subscript has type 'char' [-Wchar-subscripts] ++z[s[0]]; ^
Code
#include <iostream> using namespace std; int N; int z[256]; int main(){ cin >> N; for (int i=0; i<N; ++i){ string s; cin >> s; ++z[s[0]]; } string ok; for (int i='a'; i<='z'; ++i){ if (z[i]>=5) ok+=i; } if (ok.size()==0) cout << "PREDAJA\n"; else cout << ok << "\n"; }
Test details
Test 1
Verdict: ACCEPTED
input |
---|
18
babic keksic boric bukic ... |
correct output |
---|
bk |
user output |
---|
bk |
Test 2
Verdict: ACCEPTED
input |
---|
6
michael jordan lebron james ... |
correct output |
---|
PREDAJA |
user output |
---|
PREDAJA |
Test 3
Verdict: ACCEPTED
input |
---|
10
wmyrsaney raqdxrb cnwkmtcokgskaxosctzyks wlusaisfibbkwwzdqhezuj ... |
correct output |
---|
w |
user output |
---|
w |
Test 4
Verdict: ACCEPTED
input |
---|
20
jgztazpytubijfsmjz bokvgratzzdibku qineboilzoqdqivc bfctyltibtkbxq ... |
correct output |
---|
b |
user output |
---|
b |
Test 5
Verdict: ACCEPTED
input |
---|
50
wkrtpgfjmzlnqigogi knqkkelytfjgmyxgyzcfd xdkjrptlcuzwqgvrtzdbybh vscbjbji ... |
correct output |
---|
efv |
user output |
---|
efv |
Test 6
Verdict: ACCEPTED
input |
---|
100
cmksprocpmkl deyorcxeehlalonan tdoqxhvygiwbbklj rvamqpuprhynwduswppa ... |
correct output |
---|
dfqrt |
user output |
---|
dfqrt |
Test 7
Verdict: ACCEPTED
input |
---|
130
assootmfjtgcagtxh elqyysidg otuxclnjhvxdadm qmczmsgavvcboahqilzcuzm ... |
correct output |
---|
abcdefghijklmnopqrstuvwxyz |
user output |
---|
abcdefghijklmnopqrstuvwxyz |
Test 8
Verdict: ACCEPTED
input |
---|
60
ljuolrxkieqkobvikuyvt rhbrswllwycioayqjdertvb xmzcubmbbed uwgjslybqarciupgixt ... |
correct output |
---|
eflmnr |
user output |
---|
eflmnr |
Test 9
Verdict: ACCEPTED
input |
---|
5
pnmdjqteyiapkhvebbqtwnnh pirfyzgoqjsdsio pkcltfhwxemgyubef pxcjeh ... |
correct output |
---|
p |
user output |
---|
p |
Test 10
Verdict: ACCEPTED
input |
---|
20
fnuxegvwdqnkmkclmwlxeh kmurkl rlhxoacqadnzle foxonevsx ... |
correct output |
---|
PREDAJA |
user output |
---|
PREDAJA |
Test 11
Verdict: ACCEPTED
input |
---|
81
pidkcuqljmxi mcpwm zyyjrvkkkwkabwppvpm aoighmgashjtvl ... |
correct output |
---|
cegiptuwx |
user output |
---|
cegiptuwx |
Test 12
Verdict: ACCEPTED
input |
---|
100
evyottlutpqus openmtwnmme yvtgrk shhpzhlgmpnnvswcpmjqiwe ... |
correct output |
---|
PREDAJA |
user output |
---|
PREDAJA |
Test 13
Verdict: ACCEPTED
input |
---|
99
yuqgzaqmnwrghzntlv mcjkwfrkzchiauues uclswdwkhtvkcsvklyhyiw tggmfkr ... |
correct output |
---|
abeklmnqtvz |
user output |
---|
abeklmnqtvz |
Test 14
Verdict: ACCEPTED
input |
---|
4
kzyulnmhnmkowhtgrqksru xkgzlbwihowzdaodfg nvxkdrltxviwyhkf npvivwibxwrludfouga |
correct output |
---|
PREDAJA |
user output |
---|
PREDAJA |
Test 15
Verdict: ACCEPTED
input |
---|
78
qdidvlkgpxjxmuqq kgbugcncxazixwtxtww abwtlqxkrusaocu esjmgrutkzebklqt ... |
correct output |
---|
ajlstxz |
user output |
---|
ajlstxz |