QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#716017 | #9578. 爱上字典 | qzez# | RE | 414ms | 36020kb | C++14 | 985b | 2024-11-06 14:05:27 | 2024-11-06 14:05:33 |
Judging History
answer
#include <bits/stdc++.h>
using namespace std;
const int maxn=500006;
int read(){
int ret=0,f=1;char ch=getchar();
while(!isdigit(ch)){if(ch=='-')f=-f;ch=getchar();}
while( isdigit(ch)){ret=(ret<<3)+(ret<<1)+(ch&15);ch=getchar();}
return ret*f;
}
string s[maxn],c;
set<string> mp;
int n,num;
int main(){
while(1){
cin>>c;
int len=c.length();
if(isdigit(c[0])){
for(int i=0;i<len;++i){
n=n*10+c[i]-'0';
}
break;
}
++num;
if(isupper(c[0])) c[0]=c[0]-'A'+'a';
for(int i=0;i<len;++i){
if(isupper(c[i])||islower(c[i])) s[num]=s[num]+c[i];
}
}
for(int i=1;i<=n;++i){
cin>>c;
mp.insert(c);
}
int ans=0;
for(int i=1;i<=num;++i){
if(mp.find(s[i])==mp.end()){
mp.insert(s[i]);
ans++;
}
}
printf("%d\n",ans);
return 0;
}
详细
Test #1:
score: 100
Accepted
time: 5ms
memory: 19408kb
input:
I love Liaoning. Love Dalian! 1 love
output:
3
result:
ok single line: '3'
Test #2:
score: 0
Accepted
time: 0ms
memory: 19320kb
input:
Sulfox Loves Furry! Fur fur Furred. 2 anthropomorphic furry
output:
4
result:
ok single line: '4'
Test #3:
score: 0
Accepted
time: 0ms
memory: 19588kb
input:
Ginkgo leaves dance lightly and fall, reflecting the autumn light on the golden ground. Time is as peaceful as when we first met. 5 ginkgo reflect is as we
output:
17
result:
ok single line: '17'
Test #4:
score: 0
Accepted
time: 403ms
memory: 36020kb
input:
Eunuchism overterrible furbelow gantlet. Sophism thyroiditis thermoelectricity hassel misreward Barolong biradiated? Sweetie fatal delinquence unseemlily beamish inwork, azyme kamias Hans asteatosis synderesis champleve cheth? Dinitrile podial presentee! Waxmaker scleroscope ratably hectography lamp...
output:
201961
result:
ok single line: '201961'
Test #5:
score: 0
Accepted
time: 404ms
memory: 35948kb
input:
Unsubsidiary unsacrificeable hacking colberter pseudoappendicitis rufescence tumbak? Hypocrize aithochroi. Spina machar proximation? Chaperone vermicide virescent Klan preplacental unabsolvedness Sarcosporida noveletter waspishness sponge trustle bistetrazole prepositure melamed, cinephone. Physopho...
output:
201951
result:
ok single line: '201951'
Test #6:
score: 0
Accepted
time: 413ms
memory: 35864kb
input:
Baikerite discontentful semicitizen Acoemetic veracity pretechnical bloodweed cytogenetic icebound disrelishable leader meltedness heroship sciniph gunsel fatalistically unreasoned anticatarrhal? Unmentioned! Overaddiction broomy misapplication hecte inflammable disheart dicaryon blacktail prisonabl...
output:
201759
result:
ok single line: '201759'
Test #7:
score: 0
Accepted
time: 414ms
memory: 35888kb
input:
Dizoic filtering damenization bistipuled Opisthothelae multiangular blaff mortally. Perfusive alkaptonuria possessorial coinstantaneousness Stanhopea Nascan. Ankylostoma aumil oxygenicity cubhood abandonee fishman poppy pickpole synkinesis arteriosclerosis coloproctitis prematrimonial pseudoviaduct ...
output:
202281
result:
ok single line: '202281'
Test #8:
score: -100
Runtime Error
input:
Thelorrhagia me Camaldulian Menfra me drugman pneumonolithiasis, fructose me inwit caubeen manchet! Enjeopardy me quindecennial me unrecompensable creaturize undiverting bitty dama interteam curfew excedent me me. Revealingness Nipponism opticity suwe me stilty me antiquarism Iacchic me contrapuntal...