QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#197109#6562. First Lastucup-team580WA 954ms133628kbC++204.4kb2023-10-02 11:35:222023-10-02 11:35:22

Details

Tip: Click on the bar to expand more detailed information

Test #1:

score: 100
Accepted
time: 0ms
memory: 3544kb

input:

3
attic
climb
alpha

output:

2

result:

ok single line: '2'

Test #2:

score: 0
Accepted
time: 1ms
memory: 3532kb

input:

22
agora
alpha
antic
aorta
apnea
arena
aroma
attic
basic
blurb
china
circa
civic
climb
cobra
cocoa
comic
comma
conic
crumb
cubic
cynic

output:

6

result:

ok single line: '6'

Test #3:

score: 0
Accepted
time: 1ms
memory: 3456kb

input:

3
ccabaabbba
acbbbacccb
ccccccacba

output:

1

result:

ok single line: '1'

Test #4:

score: 0
Accepted
time: 0ms
memory: 3512kb

input:

11
mraa
myga
vtwm
mala
vvgm
atvv
vusm
mznv
avea
atfv
amgv

output:

7

result:

ok single line: '7'

Test #5:

score: 0
Accepted
time: 1ms
memory: 3596kb

input:

1000
vznwivhoprv
pvzcjyruxv
phykv
vozinczup
vbp
vgjxfotuhzhobfp
pbv
vygphslv
vpnqrfep
vzrphpfggoqcgv
vgdjmzuckyedpnp
vatmaxfp
ppnmmwtqmv
paawwp
pspoycv
vcjthv
ppcvagp
pteiqdonkklp
vav
vcsxv
priqwbalidav
vinp
phqeijnqkgbxv
pwvmbivmgvouv
vwzhndzmqpcwkmp
pyzlv
vtvblfov
vrdv
vzrfmjdnaruwp
pfup
pwzv
vwyv...

output:

478

result:

ok single line: '478'

Test #6:

score: 0
Accepted
time: 1ms
memory: 3652kb

input:

1000
rlp
pgscawiivpjndlp
pxr
ruzutr
pqdhfniemqvvr
rvar
rp
prarwp
pkuinxempbmear
rupxuanwlvawmr
pp
rzfvr
rcsxoyirp
pgpilljr
pogeizvqlr
rajolbgzswur
rcap
ryzqymwr
rrpp
rbxtr
rfldblbesyhqr
rjidcekyrir
pqrycftr
rftwgmmakykkmep
pehkxkayuip
pguxsgtuikvp
rtxmynvoolrp
pzmsljlpcr
phcfdr
plaop
rydojaccp
pzfr
...

output:

246

result:

ok single line: '246'

Test #7:

score: 0
Accepted
time: 0ms
memory: 3616kb

input:

1000
ffn
fgikjn
fwtakdbjn
fsjnfzzn
feqmuasubirsf
faypin
fcsdhfjvncfzsn
nbcmvxemkan
ngoqtaaon
nlovkxxrbn
fhdqkltoxvif
fxpnqbguftsrhff
fyniukvsmlf
fibwbqckjpojglf
nwcvf
fxgeivnakggcn
nn
fkghlusecf
neuwdafrkzptwf
fcxn
ff
nlkxtn
fdlsijtpbcjjcbn
frlcjjnpsn
ntyabhf
nvf
fdlmlhebidazhn
fjn
fstxgnmfof
fqhusf...

output:

496

result:

ok single line: '496'

Test #8:

score: 0
Accepted
time: 0ms
memory: 3512kb

input:

15
adb
bdc
cda
aeb
bec
cea
afb
bfc
cfa
agb
bgc
cga
ahb
bhc
cha

output:

15

result:

ok single line: '15'

Test #9:

score: 0
Accepted
time: 1ms
memory: 3460kb

input:

1
alpha

output:

1

result:

ok single line: '1'

Test #10:

score: 0
Accepted
time: 0ms
memory: 3580kb

input:

3
alpha
beta
gamma

output:

1

result:

ok single line: '1'

Test #11:

score: 0
Accepted
time: 0ms
memory: 3516kb

input:

2
alpha
beta

output:

1

result:

ok single line: '1'

Test #12:

score: 0
Accepted
time: 0ms
memory: 3480kb

input:

20
ccbccaabaa
aaccbbbbab
bcbcbccabc
bbbabcbbcc
ccaaccabca
acabbbccab
baacbcbccc
bcbbabbbbc
bccbbbbabc
bacaccbcac
cbbabbbaca
ccaaacbaaa
acbbbaccab
bcaacaaacc
aabbaabcbb
bbbabbbbcc
aabcaaabcb
aabbbaaacb
acacaababb
abacccccbb

output:

8

result:

ok single line: '8'

Test #13:

score: 0
Accepted
time: 0ms
memory: 3476kb

input:

20
acccccbcbb
bccbccaaac
aabbcbbccb
ababcabccb
abcaabbcab
ccabbabcca
bbccaaacbc
bbabacbccc
babacbaacc
bcabaacbac
acbabaabbb
caaccbacaa
bccccbcbcc
abbbbbbcbb
bbcbaabaac
abccaabccb
cacacaccca
bcbbcbcacc
bcccaabcbc
cabaaaccca

output:

9

result:

ok single line: '9'

Test #14:

score: 0
Accepted
time: 1ms
memory: 3552kb

input:

20
bcbbbababc
baccababbc
bcccbaacbc
ccccacbaca
aaaaccabbb
cbbbacbaaa
aaabbaabcb
aacccbbacb
bcbccbcacc
caabacbcba
bcbcbbcbbc
cacccabcaa
abbababacb
aacaabbccb
abbcacaccb
caaccaacca
bcbacacaac
baccbcccbc
abbcaccabb
acbacccccb

output:

13

result:

ok single line: '13'

Test #15:

score: 0
Accepted
time: 0ms
memory: 3484kb

input:

20
babccbbbbc
accacaabcb
acacabaabb
bacbccacac
cacacaacaa
cacaaaaaca
bccbccacac
acbaccabbb
ccbacaccba
acbaaababb
ccacabcaaa
bbabbcabcc
bacbccccac
bcacaacacc
ccabcbbbaa
aaababbbab
bbbbbabbac
abbcaabbbb
bababbabac
aaabcbbacb

output:

12

result:

ok single line: '12'

Test #16:

score: 0
Accepted
time: 0ms
memory: 3512kb

input:

20
aacbaacccb
cbcbcacaaa
cacbacbaca
aabacccacb
bbbcbacbcc
cababcacaa
bbcaaacbbc
ccccacaaca
cabcbcccaa
bbcbccabbc
ccababccca
aaacbaabbb
baacabacbc
accbbcbbab
cccbccabba
cbccaaaaca
cbcabaccca
caaacbccca
acaaabccab
bbbaaabbac

output:

10

result:

ok single line: '10'

Test #17:

score: 0
Accepted
time: 1ms
memory: 3468kb

input:

20
aaacaacbcb
cccccccaca
abbabbcacb
accaacbabb
bacbaccbac
cbcbbcccba
bacbcabcac
abaabcabab
acaaacaaab
bacbbaccac
baababbbbc
caaaaabaca
abacaccacb
abbbcbccbb
cbcbcbbcaa
cabbcaabba
cbccbaccaa
ccbbcabbaa
ababababcb
abcbcbcabb

output:

9

result:

ok single line: '9'

Test #18:

score: 0
Accepted
time: 1ms
memory: 3512kb

input:

20
bcaccbabbc
caaaaccaca
acbaacabab
aaabbabbcb
ccccaccaca
bcacbaacbc
cbccacabca
ccbabbaaaa
ababcbaaab
caabacabca
bbbcaabcac
cccccababa
aabbabcccb
abaaaccbbb
bcabaabbcc
bcbbbaacac
acaacbbccb
bacabbabcc
bbcbccbbac
aacbabccbb

output:

7

result:

ok single line: '7'

Test #19:

score: 0
Accepted
time: 0ms
memory: 3524kb

input:

20
cbacccbaba
caccbccaba
abcaccacab
cbcccabaca
acccbccacb
bccacbbabc
bbacabacac
abbcccbbab
acaaaabbcb
cbbbaabaca
babbbccacc
bbabccbcbc
cabaababaa
caacbabcba
aaaaaacccb
ccaaacacaa
baccaabcac
aaaacbcbab
baacaaaabc
ccabcacaba

output:

8

result:

ok single line: '8'

Test #20:

score: 0
Accepted
time: 0ms
memory: 3508kb

input:

20
bbaccaccbc
cabcccabba
bcabbbbaac
caaacccaca
cabccbabaa
abccaaacab
ababbccabb
acccaaabab
bababbcacc
acabbacacb
accccbcaab
cabaaccbca
cccacbbcca
acabbaccab
baacccacbc
bacacabbcc
aabaaaacab
cbbabcccba
aaaacbaccb
cccbaaaaca

output:

12

result:

ok single line: '12'

Test #21:

score: 0
Accepted
time: 0ms
memory: 3508kb

input:

20
aabacacacb
abaccaccbb
acaccccbcb
cbacbcccca
cccccabbaa
bbbcbabccc
cabbccccba
babcbcabac
baccbaacbc
ccbbccbbba
aacaabbbab
bccaccacac
abbcacaccb
cbcaabacba
babbcbaacc
ccabbbbbaa
cbcbbbaaba
bcaabcbaac
bcbbbcbbbc
babccbbbac

output:

13

result:

ok single line: '13'

Test #22:

score: 0
Accepted
time: 1ms
memory: 3576kb

input:

17
hydrogen
nitrogen
helium
neon
magnesium
niobium
molybdenum
newdymnium
holmium
hafnium
neptunium
mendelevium
nobelium
hassium
meitnerium
nihonium
moscovium

output:

6

result:

ok single line: '6'

Test #23:

score: 0
Accepted
time: 1ms
memory: 3504kb

input:

10
cbabbbcabb
bacbacbcba
bcacacacba
bbabbbbbac
acaccccbac
bbbbababca
bacabccaac
aacbcaabcb
bacbabaaaa
acabcabccb

output:

3

result:

ok single line: '3'

Test #24:

score: 0
Accepted
time: 430ms
memory: 74792kb

input:

100
ccbcaccbab
bbcbcbbbca
acbbbbbcbb
bacabcbcba
aaaabcbaac
babaaabbba
bbbabbbabc
bccaaacbac
acacaccbaa
acbacbcaac
baccabcccb
bbabcccbca
acbabaaaac
bcbbcabacc
ccbbacbcbc
aaaabcbcaa
aacbbbaaaa
bbabbcacac
baabacbbcc
abaccbabab
abcbbabacb
cbbbaccbcb
bbabbcabca
bcbaacacaa
aabccaacca
bcabaaacca
acbcbacbbc...

output:

32

result:

ok single line: '32'

Test #25:

score: 0
Accepted
time: 41ms
memory: 17028kb

input:

1000
pfalakkgegzhogw
wkkuxghywruwxfe
wyejymxprfudmww
pzfhykyprexdzjp
euglzawfswzsicw
wukfsntcitmqqsp
ptedktsjhdybegp
woiewjinnixhftw
pwysrvatyqcgxcp
pyslupqwmpqluzw
ezwtyuflrtgjdle
pyecuqzysscnqvp
pualunhhvihcohe
eemgrxaolvkxmup
egvaujnrfthojvw
ekfhcvufcqcrhcw
ecqzrgboomfjcve
whxlumclfpgcanw
pfoxyrw...

output:

225

result:

ok single line: '225'

Test #26:

score: 0
Accepted
time: 3ms
memory: 4460kb

input:

30
rfiuianksyzpkqz
zkntbrwccnjcnzh
hvyhatniqoeptvh
zzwxgtvocagvdlz
hkvtotqsilzpexr
rmqjlxhiyuvtwrh
ziynrswzgzpnfnz
rntoducfmkqpaoz
rgzweicxeqajpzr
zjznfxgpfgshkbr
rmtmhwrzkenopsz
hyodaehasivoabz
hkgxlvuxonzlvgr
hcjelcmekbohgxr
zkdlkppyvchvimh
rehlcscmhbnjexr
rhhhexryikreroz
htuwcazhktbrvqr
hvnicynkr...

output:

11

result:

ok single line: '11'

Test #27:

score: -100
Wrong Answer
time: 954ms
memory: 133628kb

input:

300
bzpjihkgvkrwzav
bssiintigbaccyv
asuzprjzymuwkfv
blajmgohbmihtwb
bwocwcqekqwuwab
azkbjbrjdnwgzhb
aqdgacdlcofzjzb
vvqgvpdtsphhqbb
vafommzgswakrub
bizlmhzwvokxezb
btwrjkdkxiaciaa
bgyfvakbcgcaima
vtkthaktjltsvtv
vmyxovrkpphmnna
bgwhfiinpdjigza
vaghbpbabwfsnub
atztqndgqetgbzv
agtepkzcnnrlfzb
ayktyzbv...

output:

124

result:

wrong answer 1st lines differ - expected: '196', found: '124'