QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#656887 | #5306. Da Mi Lao Shi Ai Kan De | ShiyuKirara | AC ✓ | 8ms | 3872kb | C++20 | 3.0kb | 2024-10-19 13:49:23 | 2024-10-19 13:49:23 |
Judging History
answer
#include<bits/stdc++.h>
#define inf 1e18
using namespace std;
using ll = long long;
#define int long long
#define PII pair<int,int>
#define all(a) a.begin()+1, a.begin()+1+n
int gcd(int a,int b){return b==0?a:gcd(b,a%b);}
#define ios ios::sync_with_stdio(false), cin.tie(0), cout.tie(0)
const ll N=2e5+10,mod=998244353,INF=1e9+10;
map<string,int> mp;
void solve(){
int n;
cin>>n;
int cnt=0;
for (int i=0;i<n;i++){
string str;
cin>>str;
for (int i=0;i<str.size();i++){
string str2=str.substr(i,3);
if(str2=="bie" && !mp[str]){
cnt++;
mp[str]=1;
cout<<str<<endl;
break;
}
}
}
if(cnt==0)
cout<<"Time to play Genshin Impact, Teacher Rice!"<<endl;;
}
signed main(){
ios;
int T=1;
cin>>T;
while (T--){
solve();
}
return 0;
}
//Shift+Alt+F格式化
//⠀⠀⠀⢛⢆⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣀⠤⠀⠀⠂⣠⡀⢀⣀⠀⠠⢄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠠⡄⠀⠀⠀
//⠀⠀⠀⠀⠀⠈⠀⠀⠀⠀⠀⠀⠀⢀⢤⢤⡘⠀⠀⠀⠀⠔⠋⠘⢆⠀⠙⢦⠀⠑⠢⡀⠀⠀⠀⠀⠀⠀⠀⠀⠃⠀⠀⠀⠀⠀⠀⠀⠀⠀
//⠀⠀⠀⠀⠀⠀⠀⠣⠀⠀⠀⠀⠠⢢⠃⠀⠈⠀⠀⠀⠀⠀⠀⠉⢿⣷⡀⠀⠑⡄⠀⠈⢢⠀⠀⢀⡀⠀⢰⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
//⠀⠀⠀⠀⠀⠀⠀⠀⡀⠀⠀⠰⠡⡟⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠈⢻⣧⠀⠀⠙⠀⠀⠀⣇⠀⠀⠀⠀⠚⠁⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
//⠀⠀⠀⠀⠀⠀⠀⠰⣇⠀⠰⠁⠀⠀⠀⠀⣴⠀⠀⠀⠀⠰⢧⠀⠀⠘⣿⡄⠀⠀⠀⠀⠰⡌⣱⡄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
//⠀⠀⠀⠀⠀⠤⠀⠀⠉⠀⡁⠀⠀⢠⠀⠀⢎⡆⠀⠀⠀⠐⡤⠵⢖⢲⣿⣇⠀⠀⠰⣦⣦⡈⢫⣃⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
//⠀⠀⠀⠀⠀⢠⡀⠀⠀⢀⡅⣤⠀⣼⠒⠞⣀⡣⣤⣤⣤⣴⢷⣤⣤⠷⣮⢿⠀⠀⠀⠀⠈⠹⡰⠳⠁⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
//⠀⠀⠀⠀⠀⠀⠀⠀⠀⠘⠃⣿⣀⣿⡾⢷⡖⢶⡄⠉⠁⠈⠀⢏⠁⠉⠹⢘⠀⠀⠀⠀⠀⠀⣼⠷⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
//⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⡏⣿⡄⠘⠧⡁⠀⠇⠀⠀⠀⠀⠈⠀⠀⠀⠈⠀⠀⣾⣦⣶⣤⣿⣦⠲⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
//⠀⠀⠀⠀⠀⠀⠀⠀⠀⠘⣠⢁⢹⣇⠀⠀⠀⠀ ~~~ ⠈⣠⠀⠀⣿⣿⣿⣿⡿⣿⣧⡘⢄⠀⠈⠀⠀⠀⠀⠀⠀⠀⠀⠀
//⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠁⣾⢸⣿⣦⣀⠂⠀⠀⠀⠀⠀⠀⠀⠀⠔⠊⢹⠀⠀⡹⠛⠟⠁⠠⣇⠛⠿⢦⡑⢄⠀⠀⠄⠀⠀⠀⠀⠀⠀
//⠀⠀⠀⠀⠀⠀⠀⠈⠀⠀⢠⣈⣸⡟⠁⠈⡹⠛⠉⠉⠉⢒⡀⢔⠁⠀⠀⢸⣿⣿⣷⠀⠀⢀⡠⡚⢦⣒⣄⠈⠀⠑⠤⡀⠀⠀⠀⠀⠀⠀
//⠀⠀⠀⠀⠀⠀⠐⠁⢀⡠⢺⣿⣿⡟⠀⠀⠈⠢⠇⠀⡀⢺⡶⣾⣕⣄⡀⣼⣿⣿⡿⠀⠉⠁⠀⠘⡄⠱⢿⣿⣄⡀⠑⠌⠢⡀⠀⠀⠀⠀
//⠀⠀⠀⠀⠀⠀⢀⠴⣋⢠⣾⣿⣿⡁⠀⠀⠀⠀⠀⡸⢁⣿⠇⣿⢻⣷⡍⢾⣿⣿⣿⡄⠀⠀⠀⠀⣸⢧⠈⢻⣿⣿⣦⣀⣀⢠⠀⠀⠀⠀
Details
Tip: Click on the bar to expand more detailed information
Test #1:
score: 100
Accepted
time: 0ms
memory: 3664kb
input:
6 1 biebie 1 adwlknafdoaihfawofd 3 ap ql biebie 2 pbpbpbpbpbpbpbpb bbbbbbbbbbie 0 3 abie bbie cbie
output:
biebie Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! bbbbbbbbbbie Time to play Genshin Impact, Teacher Rice! abie bbie cbie
result:
ok 8 lines
Test #2:
score: 0
Accepted
time: 8ms
memory: 3820kb
input:
10000 3 g a a 2 t a 1 l 0 0 1 a 3 h m g 2 b g 1 g 0 2 a a 0 1 a 1 e 0 1 a 1 g 0 1 c 1 a 1 d 1 h 2 a g 0 1 i 0 1 z 1 a 2 z d 1 l 1 g 0 2 e h 3 a a a 1 e 0 2 b a 2 e a 1 r 1 c 5 z a r k e 0 2 c a 1 z 2 g d 1 e 2 g g 0 2 e e 0 1 a 0 1 h 0 1 c 1 a 1 b 0 1 b 1 b 1 a 4 a z e i 0 1 e 0 0 0 1 e 2 x g 1 c 1 ...
output:
Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice!...
result:
ok 10000 lines
Test #3:
score: 0
Accepted
time: 4ms
memory: 3864kb
input:
10000 1 dd 0 0 1 nv 1 in 1 hl 0 1 tt 0 0 0 1 bc 0 0 2 nn ij 0 0 2 tt dd 0 0 1 in 0 1 au 0 0 1 ho 1 hc 0 0 1 df 0 1 hk 0 0 0 1 ah 0 0 1 ie 0 0 1 cc 0 1 mc 0 1 ie 0 0 1 el 0 1 bc 0 0 0 1 dd 1 ob 3 ew ab ij 0 0 1 ij 0 0 1 ik 0 0 1 ab 0 1 ak 1 vw 0 0 0 0 1 ew 0 1 uj 0 1 cc 0 1 vw 1 ii 0 1 tt 0 0 0 1 bc ...
output:
Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice!...
result:
ok 10000 lines
Test #4:
score: 0
Accepted
time: 0ms
memory: 3564kb
input:
10000 0 0 0 0 1 lel 1 ffq 0 0 0 1 abc 0 0 0 0 1 nyn 0 0 0 1 bie 0 0 1 abb 0 0 1 bie 0 0 0 1 bie 0 0 1 bie 1 bie 0 1 bie 0 1 npi 1 bie 0 0 0 0 1 sws 0 0 1 ysy 0 0 1 abc 0 1 wjw 0 1 ccc 0 1 aia 0 1 aia 0 1 ioi 0 1 bie 0 0 0 0 0 0 1 bie 0 1 bie 0 1 bie 0 0 1 bkb 0 1 bie 0 0 0 0 1 abc 0 0 0 1 mum 0 0 1 ...
output:
Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice!...
result:
ok 10000 lines
Test #5:
score: 0
Accepted
time: 8ms
memory: 3580kb
input:
10000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 ...
output:
Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice!...
result:
ok 10000 lines
Test #6:
score: 0
Accepted
time: 4ms
memory: 3624kb
input:
10000 0 0 0 0 0 0 0 0 0 0 0 0 1 abcbbieebbcbieiebc 0 0 0 0 0 0 0 0 0 1 iitii 0 0 0 0 0 0 0 0 0 0 0 0 1 dbibie 0 0 0 0 0 0 1 tatbietxtatc 0 0 0 0 0 0 0 0 0 0 0 0 1 ab 0 0 0 0 0 0 0 0 0 0 0 0 1 bbiejbibie 0 0 0 0 0 0 0 0 0 0 1 bievdbieed 0 0 0 0 0 0 0 0 1 tatbietxtatc 0 0 0 0 0 0 0 0 0 1 cdcdcdcdcdcdc...
output:
Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice!...
result:
ok 10000 lines
Test #7:
score: 0
Accepted
time: 0ms
memory: 3512kb
input:
10000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 kmkikmkekmkikmknkmkikmke 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 abbiecdacbiedabcbcdacdabdabiebcdc 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 sgsesgsbs...
output:
Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice!...
result:
ok 10000 lines
Test #8:
score: 0
Accepted
time: 8ms
memory: 3796kb
input:
10000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 oqnj 0 0 0 0 0 0 0 0 1 dmmmdmdmm 0 0 0 0 0 0 0 0 0 0 0 1 bie 0 0 0 1 svbieeie 0 0 0 0 0 0 0 0 0 0 0 0 1 bibieiesr 0 0 0 0 0 0 0 0 0 1 mmmmmmmx 0 0 0 1 bieiebiey 0 0 0 1 bbie 0 0 0 0 0 0 0 0 1 bbie 0 0 0 0 0 1 oqnj 0 0 0 0 0 0 0 0 0 0 0 1 ndnd 0 0 0 0 0 0 0 0 0 0 0...
output:
Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice!...
result:
ok 10000 lines
Test #9:
score: 0
Accepted
time: 0ms
memory: 3560kb
input:
10000 0 0 1 biee 0 0 0 1 atay 0 0 0 0 0 1 atay 0 0 0 1 bbie 0 0 0 0 1 gbbie 1 bieyno 0 0 0 0 0 1 biee 1 kskwk 0 0 1 zbie 0 0 0 0 0 0 1 tbibie 0 0 1 biee 0 0 0 0 1 abbie 0 0 1 xhhh 0 1 biebie 0 1 bie 0 0 0 0 0 0 1 bie 0 0 0 0 0 1 biebie 0 0 0 0 1 tptb 0 0 0 0 0 0 0 1 bibxbi 0 0 0 0 0 1 bief 0 1 nrnt ...
output:
Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! biee Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher ...
result:
ok 10000 lines
Test #10:
score: 0
Accepted
time: 4ms
memory: 3872kb
input:
10000 0 0 0 0 0 1 ghgghghggh 0 0 0 1 fls 0 0 0 0 0 1 imbiebieie 0 0 0 0 0 0 0 0 0 0 0 1 jbieieeha 0 0 0 0 0 0 0 0 1 bbbie 0 0 0 0 0 0 0 1 bbbiehfbie 0 0 0 0 0 0 0 0 0 1 abcbcac 0 0 0 0 0 0 0 0 0 0 0 0 0 1 bie 0 0 0 0 0 0 1 ab 0 0 0 0 0 1 abbabb 0 0 0 0 0 0 0 0 0 1 bieiebieb 0 0 0 0 0 0 0 1 gbllgbllg...
output:
Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice!...
result:
ok 10000 lines
Test #11:
score: 0
Accepted
time: 1ms
memory: 3824kb
input:
100 7 tttttbiebietbied cbacbiebacbacb uruururuuruururuu abbabaabbaa uouguouquouguouku fff abbieedbiebieabcbc 9 bieiee uruururuuruururuu uruururuuruururuu biessbiess ypyhypybieehy tvtotvtztvtotvtitvt fff ypyhypybieehy abbiebcdeacbiebdeabc 14 biessbiess ffrrfffuhff bibiee abbiebcdeacbiebdeabc dddddddd...
output:
tttttbiebietbied cbacbiebacbacb abbieedbiebieabcbc bieiee biessbiess ypyhypybieehy abbiebcdeacbiebdeabc bibiee hgbiegbiegdmhgdmhgd biebiek hbiehphhphbiehph biee bmbpbie biejlbielt bbieeieebieebieebiee bbie abcbibieea lbiel mpbiep bieee biebccccaa abbiebaba Time to play Genshin Impact, Teacher Rice! ...
result:
ok 115 lines
Test #12:
score: 0
Accepted
time: 0ms
memory: 3600kb
input:
100 7 dalpigmbjnpdalpigmbjnpdalpigmbjnpdalp abieeacabbcbiebabieababcbbiec beabdebbbaabddbecffcabfebeabde nonhnonknonhnonynonhnon abcbcacabbcacababccbiebcbcabcacbiebc beabdebbbaabddbecffcabfebeabde cdablkjdgcllcgaaglbiebbiedfc 9 fzffffbiefbiezz dalpigmbjnpdalpigmbjnpdalpigmbjnpdalp aaaaaaaaaaaaaaaaaa...
output:
abieeacabbcbiebabieababcbbiec abcbcacabbcacababccbiebcbcabcacbiebc cdablkjdgcllcgaaglbiebbiedfc fzffffbiefbiezz nfnybieunfnynfbiefnynbienfnyn oqoroqoioqoroqovoqorbieibieroqot Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Ri...
result:
ok 107 lines
Test #13:
score: 0
Accepted
time: 1ms
memory: 3664kb
input:
100 11 wwiiwiio bie mmemmeme lvvvvvvvm biebiec bibienk fwffwfw kgidkgi bie ccc kgidkgi 22 xgxmx clvllk abcbcaca biez bibienk abaaba rxrtrx uwcii bieiedbie wywwyw abbieee tat alam abiec bie eieei abcdb abbaba cec bieieo bie cbbbbbaac 3 bibie bie abcbie 0 3 bieee abcdb xgxmx 2 jvjzjvjj rxrrxr 11 abcbc...
output:
bie biebiec bibienk biez bieiedbie abbieee abiec bieieo bibie abcbie Time to play Genshin Impact, Teacher Rice! bieee Time to play Genshin Impact, Teacher Rice! abcbcbieb cbiexbiec bbie gpgbiebie gbiee bibibie bbiee ubiebieeu ebibbie abcdbieie bbieq abieee biebieie dcabieec abcbibie biee wbbieeie fb...
result:
ok 118 lines
Test #14:
score: 0
Accepted
time: 1ms
memory: 3792kb
input:
100 23 bie dsdx dlldde cvcyc bie bbie bieek ibiei efefe gbbieg bieeb eieje kgl bbbie biek dad babb bbie cgci bbbb bieve sesc gbbieg 2 bie bieek 42 yby hvh bbbb bie bbie kgl pmpb abc tbie bbie bieiey dsdx biebie fofhfo dduudu bie bie efefe bie bbbie epe bieek abcdb eheye bie bieepc fmfq biebie babb e...
output:
bie bbie bieek ibiei gbbieg bieeb bbbie biek bieve Time to play Genshin Impact, Teacher Rice! tbie bieiey biebie bieepc lbibie Time to play Genshin Impact, Teacher Rice! Time to play Genshin Impact, Teacher Rice! bieee bibie wbie bieiej bieieh bbibie bbiee Time to play Genshin Impact, Teacher Rice! ...
result:
ok 119 lines
Test #15:
score: 0
Accepted
time: 0ms
memory: 3576kb
input:
100 7 biee gq abbaba bibiee bccbccbc yjy kjk 26 zuzybie ab pspzps bbibiee xbxtxbxix ejepeje bbiebie kikk abcdbcbie kcktkckxk bbiebie ibbie ii obieuo sssx awala ddbibiedd acawaca abcdbcdacd di dbibie jyjn biebiee abcdeb ikiwik aabaa 9 bubbub iriyir sbies bie en bie sbies abbab cclczh 16 bbibiec bbieb...
output:
biee bibiee zuzybie bbibiee bbiebie abcdbcbie ibbie obieuo ddbibiedd dbibie biebiee sbies bie bbibiec kbiekk biebbbie bieieyy abieeb ooflbbiee abieiea bieebie mbieibie xbiee bieee bibie abieb bieeie bieie hhbiekhhc ppbie hobiebieo bbie rbieieenr obiebieoox bieieeeee obieo bieebiebie bieawnwdwn Time ...
result:
ok 187 lines