QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#197063#6562. First Lastucup-team580#TL 1ms3980kbC++203.9kb2023-10-02 10:37:282023-10-02 10:37:29

详细

Test #1:

score: 100
Accepted
time: 1ms
memory: 3696kb

input:

3
attic
climb
alpha

output:

2

result:

ok single line: '2'

Test #2:

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

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: 0ms
memory: 3668kb

input:

3
ccabaabbba
acbbbacccb
ccccccacba

output:

1

result:

ok single line: '1'

Test #4:

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

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: 3980kb

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: 3748kb

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: 1ms
memory: 3704kb

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: 3604kb

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: 0ms
memory: 3660kb

input:

1
alpha

output:

1

result:

ok single line: '1'

Test #10:

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

input:

3
alpha
beta
gamma

output:

1

result:

ok single line: '1'

Test #11:

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

input:

2
alpha
beta

output:

1

result:

ok single line: '1'

Test #12:

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

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: 3544kb

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: 0ms
memory: 3904kb

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: 3904kb

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: 3868kb

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: 0ms
memory: 3664kb

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: 0ms
memory: 3596kb

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: 3656kb

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: 3824kb

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: 3660kb

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: 0ms
memory: 3544kb

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: 0ms
memory: 3896kb

input:

10
cbabbbcabb
bacbacbcba
bcacacacba
bbabbbbbac
acaccccbac
bbbbababca
bacabccaac
aacbcaabcb
bacbabaaaa
acabcabccb

output:

3

result:

ok single line: '3'

Test #24:

score: -100
Time Limit Exceeded

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:

33

result: