QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#164013 | #1242. Broken line | ucup-team1600# | AC ✓ | 141ms | 3996kb | C++20 | 2.7kb | 2023-09-04 18:09:41 | 2023-09-04 18:09:42 |
Judging History
answer
//#pragma GCC optimize("Ofast", "unroll-loops")
//#pragma GCC target("sse", "sse2", "sse3", "ssse3", "sse4")
#ifdef LOCAL
#include <iostream>
#include <cmath>
#include <algorithm>
#include <stdio.h>
#include <cstdint>
#include <cstring>
#include <string>
#include <cstdlib>
#include <vector>
#include <bitset>
#include <map>
#include <queue>
#include <ctime>
#include <stack>
#include <set>
#include <list>
#include <random>
#include <deque>
#include <functional>
#include <iomanip>
#include <sstream>
#include <fstream>
#include <complex>
#include <numeric>
#include <cassert>
#include <array>
#include <tuple>
#include <unordered_map>
#include <unordered_set>
#include <thread>
#else
#include <bits/stdc++.h>
#endif
#define all(a) a.begin(),a.end()
#define len(a) (int)(a.size())
#define mp make_pair
#define pb push_back
#define fir first
#define sec second
#define fi first
#define se second
using namespace std;
typedef pair<int, int> pii;
typedef long long ll;
typedef long double ld;
template<typename T>
inline bool umin(T &a, T b) {
if (b < a) {
a = b;
return true;
}
return false;
}
template<typename T>
inline bool umax(T &a, T b) {
if (a < b) {
a = b;
return true;
}
return false;
}
#ifdef LOCAL
#define D for (bool _FLAG = true; _FLAG; _FLAG = false)
#define LOG(...) print(#__VA_ARGS__" ::", __VA_ARGS__) << endl
template <class ...Ts> auto &print(Ts ...ts) { return ((cerr << ts << " "), ...); }
#else
#define D while (false)
#define LOG(...)
#endif // LOCAL
const int max_n = -1, inf = 1000111222;
int main() {
// freopen("input.txt", "r", stdin);
// freopen("output.txt", "w", stdout);
ios_base::sync_with_stdio(false);
cin.tie(nullptr);
string s;
cin >> s;
int n = len(s);
map <pii, ll> ans;
map <int, ll> one, l, h;
for (int i = 0; i < n; i++) {
int cur = s[i] - 'a';
for (auto &j : h) {
int a = j.first;
one[a] += j.second;
int b = cur;
if (a > b) {
swap(a, b);
}
ans[{a, b}] -= j.second;
}
h[cur] += 1;
l[cur] -= 1;
l[16] += 1;
}
ll res = 0;
int val[16] = {};
for (int mask = 0; mask < (1 << 16); mask++) {
for (int i = 0; i < 16; i++) {
val[i] = bool(mask & (1 << i));
}
ll cur = 0;
for (auto &j : ans) {
cur += j.second * val[j.first.first] * val[j.first.second];
}
for (auto &j : one) {
cur += j.second * val[j.first];
}
umax(res, cur);
}
cout << res << '\n';
}
Details
Tip: Click on the bar to expand more detailed information
Test #1:
score: 100
Accepted
time: 4ms
memory: 3564kb
input:
banan
output:
5
result:
ok answer is '5'
Test #2:
score: 0
Accepted
time: 28ms
memory: 3640kb
input:
abcdefghijklmnopaaaa
output:
90
result:
ok answer is '90'
Test #3:
score: 0
Accepted
time: 1ms
memory: 3632kb
input:
a
output:
0
result:
ok answer is '0'
Test #4:
score: 0
Accepted
time: 1ms
memory: 3508kb
input:
pp
output:
0
result:
ok answer is '0'
Test #5:
score: 0
Accepted
time: 1ms
memory: 3860kb
input:
pa
output:
1
result:
ok answer is '1'
Test #6:
score: 0
Accepted
time: 2ms
memory: 3564kb
input:
abc
output:
2
result:
ok answer is '2'
Test #7:
score: 0
Accepted
time: 2ms
memory: 3504kb
input:
ede
output:
1
result:
ok answer is '1'
Test #8:
score: 0
Accepted
time: 1ms
memory: 3856kb
input:
ooo
output:
0
result:
ok answer is '0'
Test #9:
score: 0
Accepted
time: 3ms
memory: 3556kb
input:
fnod
output:
4
result:
ok answer is '4'
Test #10:
score: 0
Accepted
time: 0ms
memory: 3660kb
input:
abbaa
output:
4
result:
ok answer is '4'
Test #11:
score: 0
Accepted
time: 2ms
memory: 3600kb
input:
baabbb
output:
6
result:
ok answer is '6'
Test #12:
score: 0
Accepted
time: 3ms
memory: 3820kb
input:
ccababa
output:
10
result:
ok answer is '10'
Test #13:
score: 0
Accepted
time: 3ms
memory: 3820kb
input:
bababbdaee
output:
20
result:
ok answer is '20'
Test #14:
score: 0
Accepted
time: 11ms
memory: 3636kb
input:
djbecjaiccfhdiihhjh
output:
76
result:
ok answer is '76'
Test #15:
score: 0
Accepted
time: 4ms
memory: 3852kb
input:
adaaaadddbcdadcdaddbcdccabbddcdbddabbbbb
output:
293
result:
ok answer is '293'
Test #16:
score: 0
Accepted
time: 37ms
memory: 3800kb
input:
blpeledhbcafdfeiecmcndheagipefkfconkjldniedkacllaknlpagklpemgfkmcjlfcdogkhnncooomefofhagndkccpmbcbj
output:
1679
result:
ok answer is '1679'
Test #17:
score: 0
Accepted
time: 36ms
memory: 3832kb
input:
bnnjcbgkebbmkagekignbbkifcnanekiocbngbnljnkciikjbobdcmmkpimbmgbjgkcbfbkkkoebhijemkgjecgenkaclpiliikamjkbjnpgmacejblkjkbbicicjiijmigkjpcjhkpkjicpbhekpkdijbbmpjjbkcmbojfapkcbcigijccfnbjibjjjjimkpinkccbjfjmikcmnceecnbkkcondmeikcbjnjmdiekdnokbhkkikmmjmimfbkicmbebcmcfkigbapbbcmbbiiickbkmgnbnilhihgkhpnbbc...
output:
139281
result:
ok answer is '139281'
Test #18:
score: 0
Accepted
time: 1ms
memory: 3852kb
input:
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa...
output:
0
result:
ok answer is '0'
Test #19:
score: 0
Accepted
time: 9ms
memory: 3864kb
input:
dgffadaaegfdbgdfgdgcdeeddfedaabgbaadfcbddbfeacgdebdabebeccfcbcfdcbcaefeedgcbgcbdeefgccdeadabddgdadcfffbeefdgfdadfbgbcefgbgabggbgfefffabdgefaegdfcfdfecggaaagaceefaeefddbggcffedbccdcdcaeddcdcccagbcebgacfecbagbgdagaacfedcaafcgeebdcccecdfceaeagdafcccadegadfgaadfccgcfcfaeaafgebaeegebgfababfbefeefadaggcbd...
output:
8032403
result:
ok answer is '8032403'
Test #20:
score: 0
Accepted
time: 40ms
memory: 3856kb
input:
boaleaaebaoieafmmjkakeodmnaabkeebjeooenibaaainieniieiedeoobbeoomieaoebiipmbekoeljjeooeloomeneaaoaeaenedjlaemeebmoemaebeaeeejajmjameieanemoaleeaneaeeimaoeeebneapembkbomejmmamjeeooipbaaoemnbmoneeloenbademalebiapimnanbeemnoabeaeeemieemmeemooaaeoanefllbkleeeoenbeaiaoieimeeoeieoideemmmajeonoenebmedgmeeoe...
output:
32621356
result:
ok answer is '32621356'
Test #21:
score: 0
Accepted
time: 51ms
memory: 3964kb
input:
coanjdmbapdmpbjhfnefggihaogjplakkghhhnmmnikckhjbfjdbfhleebooecoaenicldncacejlhekbmllngcliakoaljboomadacbbnbjghbefmhddleojdpmclmkkbidjgfbpcdlkebnnbiplackhojeejojjpajkedfoipihbfipnclmdeamdgfbcmoclbdobmbofmjfdkagngajmcmgnkkfampkhkkclmmdcifppmgakkgcjhonfbblldpfncgompacnedkkfeiicnmggfpfbellepibnglpideflb...
output:
316580550
result:
ok answer is '316580550'
Test #22:
score: 0
Accepted
time: 60ms
memory: 3696kb
input:
fhnknckfgnlgdgnicnijankanoccldcfmkhojcflhdngndeccnekdjldcdadoeegdjnmkicccafomhkabbhohofiamoekagnkdkbmnhablbhchlmicfkaldmjdicdoacakdbkjmmcdfknneamannfbnjciihnkflkbmgefhngkceeegdlmifnhbfgnkiljdkelkgoeiljjhdgblladjljbfodmmiagagledbfamnjlehanjjenimloiildjndmkfgdkfndgnhcmdnaahcfbeaikiaiaackkmemekemofgkdm...
output:
1911314433
result:
ok answer is '1911314433'
Test #23:
score: 0
Accepted
time: 92ms
memory: 3760kb
input:
facdcdnicaffdknehggbcmkopemnmnfnbdeembmclfkmcihcimodhiocaaenpdpmgddlnjimojkflopabianljiaipbjainhknmdjgibkajpohkckggjlpdlfeamppepcdnokcobcifhknjdmebfchmpkhooofoanocnlcdpbampgkbjidnllacgkinaeofjikohcbabgfkffepfneijhajhmggoplpngcidoakfgodlahcnmofkienkloiajcmblgjcihbbfajpgacoomhpobhjopemckombmioplnaiijh...
output:
5029120463
result:
ok answer is '5029120463'
Test #24:
score: 0
Accepted
time: 113ms
memory: 3952kb
input:
mkdiekeijohfoieakdljedbbplpeenlhdiipknpfegpheibiofhbgnaklmknnhleofmmhieggchpmkjcbcbbjipbdlbbhfinchdmdepoaddaonnnlohpboaiaipbneppmjoblnophfjljbocfhlemnpjkmpcddcclicddhpplcommmnlmhonpnenacoppfjahfkkfdbjfaahnlkbhmjiojpfhldedjekemjadgmpfcpgoegndnnfppggaeagkhkcmoknajdajfhplheoipdfmancgpblcmpimbdicmdjmjfc...
output:
11314522779
result:
ok answer is '11314522779'
Test #25:
score: 0
Accepted
time: 115ms
memory: 3748kb
input:
nblbejjbepcebeandgolnejlplfpehhdcdomhgbiemljbeeekjfppmbelmmnomkiekfobfibcbbjjfnbjcikhkbbmeocfedojmbolnjpmmpnedgpmdlaldbfbpfopjedndpfhofpkgnladamndhapaomohdkndakmafnkkiflcnenaplopnolfnckfidmnenaomihhligcopoibpahbjnoejfmndkidfaogikbkaohjmghpiiaidimnoepngkfajpajllnpbdbiejbcplonbkkmfbpmmopbnkcnfhfoafaal...
output:
11319558496
result:
ok answer is '11319558496'
Test #26:
score: 0
Accepted
time: 114ms
memory: 3832kb
input:
oijhpjpichaldjeidapjggeiapogapfffadlifnpcfoeedcemknhpohahekjjppnpjlakgodpphnbnffbnmgefjfofaicjenfnlaoophlamgcmpfbidikdiicobiihgmkpdepeabadnhkanmkdjppgnmonikeipkfbajlbokmnfdackbkppofpdhjbigbnpdablaplajjdkcilgndnpbjlhkbmghnlccnceaknaidaegocbnoacdnibpnhmolakmcmleophgnbhldfbkmkacmifcpkpiepbnjidnniogmkgo...
output:
11326125099
result:
ok answer is '11326125099'
Test #27:
score: 0
Accepted
time: 118ms
memory: 3672kb
input:
bkchbnkbknlnmmdlkeignliofkpplhkajomloddcloaonmocecmdhinlokldgcoodohdkdlompifebdnjfmnobdnhbhbafbnnjoackhghgoiekaefmpbhmhalahpcfcoofloffhmcdccehfooebnehjjkpibiojmijideoplbadhjneghbbbgepdkeganhkifoepbohjejlnfahicjlhbepbmcfckkeemfhpjmoadgnempkkiakeledgoaceelmnnnidedkpcfnbkjhkphakcjmmjcgkmffedcddmpdeddeh...
output:
11323224455
result:
ok answer is '11323224455'
Test #28:
score: 0
Accepted
time: 109ms
memory: 3956kb
input:
jaloijhcgekiahdifidgbjnecfolobgledafgncjfmlmmgbenchenccihiceomlfchnbeelnjkeleohcdhifjooehohekmeemdfhdeiecnlchaacjaegagbhelmleghhleicnbdkgajikgcnmmhclmdoenfojecaaldoehlifggcklicmefdhjimcihhehdbhfkcmemnojlohkgmeinhfhjbggengehfkaddjajgacdgehbelmdohhohechelmcglcddhkjinmddjlclaccfnlnfbjnlagieokiihfdainnk...
output:
11264990424
result:
ok answer is '11264990424'
Test #29:
score: 0
Accepted
time: 108ms
memory: 3780kb
input:
bginfiikbcehakamkicnomkabonleibjjnagenmkicgkegcfihmlccmgejjbbamgjbnegclcmmmjbiabiocegcfnffmlgjnlekbhialcdalnbilmhcgcojoeghcknlblollcdgdnjfmoifjfadidhadmnlkdmjlflllhikbaiecomocefechjgconbnbdblokennfhhelgbinadmlmdbaicfabgelddhneeaaomecemiagdlekdmjlelglmbobfkgejcbaiochlllggiadandembgjnfehfbhdkimdooeacf...
output:
11266209262
result:
ok answer is '11266209262'
Test #30:
score: 0
Accepted
time: 2ms
memory: 3988kb
input:
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa...
output:
0
result:
ok answer is '0'
Test #31:
score: 0
Accepted
time: 11ms
memory: 3952kb
input:
baaaabbaaababaaabaabbbaabbaababbaabaabbbabbabbaabbaaabaabbabbabbbbaaabaabbaaabbbabbbaababaabaabbaabbabaabbbbbbaaabaabbaaabbabbbababbabbabbbaaaabbbbbababbabaabbaabbabbaaaabbabaabbaabbaaabbbabbbbaabbbaaaabbbbbbbbbbbabaabbabaabbbabbbabbbabaababaaaaabaaaaaabbbabaaabbbbbbbbbaabbbbabaaaabbaababbbbbabbaaab...
output:
11283120735
result:
ok answer is '11283120735'
Test #32:
score: 0
Accepted
time: 15ms
memory: 3808kb
input:
bbcbabbccccabbacabbbcbcbbbbcbbababccaacaabcbcababbbbaabbbcbbaabababcabbabaabbabaacbbcbcbbccbbcbccabbaaabcacabcbbaccabcaabcccabbcabbbabbbcacbaccbabcbbaccbabcccaabcbaaaccaabcccaaaacbabccbbcbabaacbbcacbaabaabbccccaacbcccaccaacbaabcabbbccaaaaabbbacacbbccbbbcabaabacabaaabbccaababbbbcbabcccccababccbacbaaa...
output:
10035076517
result:
ok answer is '10035076517'
Test #33:
score: 0
Accepted
time: 20ms
memory: 3924kb
input:
cdacdababbbbbabdccbacbccccacbabcadcbbcddaaadadcbaadccdaadadccbdadbbacbdbadacaaacacdddbdbdcccdbcadacbdaabdcddbbdacdbabacbadcabbbcbbbbdacbbdabcbaccbaddcadacdcdbabdaaabbbddabbdaabadcddacccddbaabcacdabbdadddadddcacaccbbcaccacdabaadbcbdbdccaababbddddbdddbbdbdaadcdaacdccaacdabbacdbbcacbdbcddcadbbddcbaddca...
output:
11309284824
result:
ok answer is '11309284824'
Test #34:
score: 0
Accepted
time: 118ms
memory: 3796kb
input:
hchdocgchdchakfcfccllhcdhgfpaoclclmddccodcoclcamcmdgacdhianddcmgcefahcckchdcchcfbdgccmdcodddbdfdffdpkmhdcchddlgfdcphcahdjccdklcdcoahdchoccdmchdpahchchefnckhlmfapgdfdfoohlkdkocodgfhlddkhchhdhkhcddaokcfcodcfkkbkkcddlhhchahpccgdddahmoocdhfcffcdckdgghfccfhdkcccdchdhccaahdhdacpdcfdchpdhchcdchdcaaddkocoda...
output:
11291928107
result:
ok answer is '11291928107'
Test #35:
score: 0
Accepted
time: 112ms
memory: 3828kb
input:
igmmniaeodfgagafemlaggmigagolajoefoagoifloamagejhinaaoagbgibmolmlgmgaaalflaaloliogafefgalmanegabaijgglijmgoggonmafcalfaclaomffamiigfonafjaeoaaglleaamlmmagegfkomaoagaganggogmhcaabmgfmaaaaaiealabloleoggeflmgaafbaamiloloamemaaalomgfgegakagelgfgfindghlllahamclllnclmgegnloigalonaihloegololggioaamglmnoami...
output:
11322837231
result:
ok answer is '11322837231'
Test #36:
score: 0
Accepted
time: 101ms
memory: 3800kb
input:
aaaegkagaagekjaieoelbagalocaagacacaecogaagfcaaekkaleaeaegoaeaabbabkehhaecbaeehabokaadllaedfaeakeckeebaeadackgaaaedeaeejamaeleeachaafclhmjbkoegaaakehaemahalmaoafmbamgafaaaaahhggeheaageoeageahanaggbeggeaaabcgaljbkkaiakmagbhamdjgalakonaeaaefbmkcheebaeabalaabaaaabaebdlakhaaaaggmcacaaeeeeiageakkdbeaahaae...
output:
11299481719
result:
ok answer is '11299481719'
Test #37:
score: 0
Accepted
time: 117ms
memory: 3752kb
input:
jehpilphidkccdjdcicplmpcjamhidnejjijjiohppdadhpcfciclmpillccpcdacpahciciodchkmpmciicceepachlpckhhjlipicochhjhidcihljhajclfiidicecjhiccdjpehipijjhfecccdhccpcidpjiphepiddphllhaicjemhpeiicdmfpamfieihichihdphplilcicdpkodcilepjhcchchcpoilhjhlijjcpjclpccpfejhopidilpcpfjabdpolioolccidcihdhpddhcickihhpjddic...
output:
11311249285
result:
ok answer is '11311249285'
Test #38:
score: 0
Accepted
time: 115ms
memory: 3780kb
input:
iimkciihfiibdppildkcmkbbkpeiebifikbkimkidhiihiicebgpmgibpibcdihcdglmihjinjiikimgjjbhnikimkgpijdipkbpclminpbiggpipiniicgjbipcpeikbinipcdebhdgbbpimcdbidkdiigmnepegdmpmkdpjhiggiknikpicpipiekgnbppidinjmppheicdgeciipeimdcpighdhkmiikbijgjpmicieiniiidkmichhimhbpmikppgigjdiipndbpdojgdhkmjmmpmjgmlkndcgdbnmib...
output:
11289686938
result:
ok answer is '11289686938'
Test #39:
score: 0
Accepted
time: 119ms
memory: 3832kb
input:
mhhhhmhplljmdlacpmdlehhopahieebcjhcmmhnhmhkjhmhkmledmldheaghemhheehmmlhhldnhmaklbaechljnmhhhmhcmcpmmhbmckdhmhkabhmmplhcpchegahoegceohhhhheeckhcmabphhhemmhgkhdecmlmhhecehmemdeeeghcdphlcegmcpejmmdfphhchaemehjbemmjpgmhhphhedbllemdllhmlhmeemhhebfnpnemlmmhchhheelmemgchlljhlbahhklikpiemmmechdeldejhhnfkbpm...
output:
11310963550
result:
ok answer is '11310963550'
Test #40:
score: 0
Accepted
time: 141ms
memory: 3804kb
input:
kflgliijhkkglmolahmhhljennklolhhmlnflelllcdlhklldllgglhllnkeaeggikelhdlpnnhklkahjheifajephhkmekhieghjlheldhhlgkfkllekkghllhdlhlklihdhhekeihlllhenlhlmoklnmlajlkeallhlepgmglfjelejakeemhlhikeghldlldlepjflimellflhllekkklejcelelljknlhlkffclloigdlllkmeehmlehkpjljnmddfnmlhlfkfemeplalenmeeehfllaeaoakeelleee...
output:
11302371678
result:
ok answer is '11302371678'
Test #41:
score: 0
Accepted
time: 105ms
memory: 3816kb
input:
nfnnngnikeficfgljnnlefeneilleenaaglhanikalggnfoknddedookleneceojakecmeknkaelfnakbjlflagnnibeanbnlnnnhbakedeeinoknnflnboeblalanoffjmhfolebbfhhejnnkjkofhjnefhnngfefobkhaileoednjfineefdlhbmekeikfeeoioenlnncbelaenanfajhklabohndalnboekfknleegmfeklkhecnflfoegfneajnemlckelfjeefekekeenobnbghlnlfkelhbkbbhenh...
output:
11299605236
result:
ok answer is '11299605236'
Test #42:
score: 0
Accepted
time: 38ms
memory: 3996kb
input:
dabdecagccbddcffddcdfbgfgddcfcdcdcffeccfcdedcfdcecfcfcfddddgcbcffcccdddcfefgbcddfdgfgdddecdafdaddcefcdbccfdgdbfgfgccfefcacfcffcfcdcdafbfcbcfcccfcdddcacdcfddccgccddfcdcfcdadceccedcdfccdcdccfacefdddffdeadfecfcfefaffcccedfcfgcfcfcfgfdcddbcdffdceffccffefeffcdaedbadddabcecbabddbaccecbcdaccdccecfccccdfdfd...
output:
11266097504
result:
ok answer is '11266097504'
Test #43:
score: 0
Accepted
time: 35ms
memory: 3800kb
input:
dabdecagccbddcffddcdfbgfgddcfcdcdcffeccfcdedcfdcecfcfcfddddgcbcffcccdddcfefgbcddfdgfgdddecdafdaddcefcdbccfdgdbfgfgccfefcacfcffcfcdcdafbfcbcfcccfcdddcacdcfddccgccddfcdcfcdadceccedcdfccdcdccfacefdddffdeadfecfcfefaffcccedfcfgcfcfcfgfdcddbcdffdceffccffefeffcdaedbadddabcecbabddbaccecbcdaccdccecfccccdfdfd...
output:
11266097504
result:
ok answer is '11266097504'
Test #44:
score: 0
Accepted
time: 114ms
memory: 3652kb
input:
aaoanalallaagollalaacaodanaaaiaalcioaadacaakaaaaanfaoldaaldcoaooapdnaafaalapaidcaacaalgaacaloaaldancnnaalaaaaipapacoliaoalapalnagndaaalaiapccioiapaaaacaaaapdakafanadcaaaldldaaaakpafaocfdpckgaaaaaafgdlpaaadaaaaipaianafdadcaaoanppnnaacaapaaaagidpnlppglanpcaplflapcalpkaoalacnaplaoaipccaafaafagaaimnfdca...
output:
11298062553
result:
ok answer is '11298062553'
Test #45:
score: 0
Accepted
time: 116ms
memory: 3952kb
input:
hhpoakpomkmhghdfhhkhhkkhokhkehhmhbpkphkhhahhhkhkjahphhhnhkahkhhhchnahnmkoohhkhmhphkhmohmnahhekkhkehphiokhkkoahkhhoakihhoghhhihhhefphakmoahfhhhhhmhkkhhhhkhhkhhhhhphhkkhhdhhnpmhhphohnidkhehokdhlphhaaahekhhhighahhmhhhahhhkhlhkhhahnhhkhhhafhnmhhhlhhalbhkahhahhhhokhemhhhoohbhhfhhehhpkihnhhhhahhahnkphahhk...
output:
11262549508
result:
ok answer is '11262549508'
Test #46:
score: 0
Accepted
time: 116ms
memory: 3788kb
input:
pnpppklnpppppffkpppnppppppbifpppkiolpppdfpppmpppnpbpkppipbppnpbpkpppinepppkpkmpdooopgpnodphhpopppppbhnpppnpiipppknpphpppppmpgkigfbphkppmobgipehpkpfppppppilppfbnpnlbnpndkpkphppoobffppfpppbpppopppplfpgdpghbppnmpoppbfpppbpbifppplppfpofppkppbphponnodpbpppkpapbpfppfpppppnppnplnpippfpbpippppfipoknpebpepph...
output:
11148220295
result:
ok answer is '11148220295'
Test #47:
score: 0
Accepted
time: 102ms
memory: 3752kb
input:
eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeedeeeeeeeeeeeeemeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeepeeeeeeeeeeeeeeeeeeeeeeeeeeegeeeeeneedeeeejeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeebeeeeeeeeeeeeeeeeeeeeeeoeeebeeeeeeeeeeeeeoeeeeeeeeeeeeeeeeeeeeeeejeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee...
output:
2119569528
result:
ok answer is '2119569528'
Test #48:
score: 0
Accepted
time: 114ms
memory: 3952kb
input:
kppkpkdpkppppmkkppkppmkppjkppppfkpdekpppkpfpkpenpbkpkmfkmkkppkkkpkppncdcpkkpkkppkppknkpppppkpkkkkpfpkppekpmkkpmmkkkpkpfpkkkkmppkpfkfkkppkpkkkkkkpkkpepkpppefokppndpfkkphpkfpkkppekkkkkpkbkpkkekpkkpknkpkpnfkkkpkpkkkepfpkmkpkpkpjkkpockkkpkpekkfkpppkkkpkekkcpkpkmppkkppkphekpmkpppkpkjkkkkpkkkapkkpkkppkmpk...
output:
11320310199
result:
ok answer is '11320310199'
Test #49:
score: 0
Accepted
time: 62ms
memory: 3748kb
input:
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa...
output:
22400000000
result:
ok answer is '22400000000'
Test #50:
score: 0
Accepted
time: 68ms
memory: 3780kb
input:
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa...
output:
22500000000
result:
ok answer is '22500000000'
Test #51:
score: 0
Accepted
time: 119ms
memory: 3816kb
input:
lbggdafkplacpcpipoohgofcefinbgmjkacmgjcolhmaaniallcehbijjpdejdcaakchchicpcddgndggpdiogaejbkdbpkjppdeffhofehaicpkkeofiehbgceilhpadfcdimibjimiafdhelmcdlpcelnbcgkfakkfdioelmlgiapccjlpnibkjlhebbjjaejibebekkefjcnffjjdeaonligkgpenlmonaghfneobaimegjppakjijikdopdldolnfmjdfoanhefjhccaknljloolekkabimnelofkioo...
output:
11330265766
result:
ok answer is '11330265766'
Test #52:
score: 0
Accepted
time: 115ms
memory: 3784kb
input:
lbggdafkplacpcpipoohgofcefinbgmjkacmgjcolhmaaniallcehbijjpdejdcaakchchicpcddgndggpdiogaejbkdbpkjppdeffhofehaicpkkeofiehbgceilhpadfcdimibjimiafdhelmcdlpcelnbcgkfakkfdioelmlgiapccjlpnibkjlhebbjjaejibebekkefjcnffjjdeaonligkgpenlmonaghfneobaimegjppakjijikdopdldolnfmjdfoanhefjhccaknljloolekkabimnelofkioo...
output:
11330265767
result:
ok answer is '11330265767'
Test #53:
score: 0
Accepted
time: 114ms
memory: 3788kb
input:
leoahnpanophdibnldpiablmngaegpfipkifhmacjcnjddckpkdkjajldlnalimabnbbanolemiadccpafciafhghglmmemjfoliogggnlcmchjmbdcekoidaeijjnhpodamhmgomkfkkglhljipakpjfjkpcahfooegllepknnoigapjpcabojigonbifomogejfpgalnnpofebflomkcbmdkfapbpaidahjgppiiepboipcndjiejogajimngkfhkoghkhncceplddfmdcacliecbfgmdjbnilipagiklg...
output:
11314337725
result:
ok answer is '11314337725'
Test #54:
score: 0
Accepted
time: 117ms
memory: 3952kb
input:
leoahnpanophdibnldpiablmngaegpfipkifhmacjcnjddckpkdkjajldlnalimabnbbanolemiadccpafciafhghglmmemjfoliogggnlcmchjmbdcekoidaeijjnhpodamhmgomkfkkglhljipakpjfjkpcahfooegllepknnoigapjpcabojigonbifomogejfpgalnnpofebflomkcbmdkfapbpaidahjgppiiepboipcndjiejogajimngkfhkoghkhncceplddfmdcacliecbfgmdjbnilipagiklg...
output:
11314337725
result:
ok answer is '11314337725'
Test #55:
score: 0
Accepted
time: 118ms
memory: 3836kb
input:
libmbjmjdnkfmbagmcpnclojpaicphciihbmhggbeoclhbpbofiijgeflcpbfgefghcdlahdcdhgefihiihiflffneaoonloiodbalboidjcealgpjbeelnchdcekbkekempcchfgjcjagocoeealfpacplfnnnfjnbbohcbhnhgdjafhnfkabgdcnlnldhfefgoplpbabkmmemckfmedhfcljfihlbeegkelbcbphhkmmpbobhllajhhipbcdlfppfoajkgfahmmieaaodmjalobglhhglbbajmhoelepcd...
output:
11310856703
result:
ok answer is '11310856703'
Test #56:
score: 0
Accepted
time: 117ms
memory: 3752kb
input:
loomodkebhanlmmecjogmlailfphncdkfgmdehdjmllgmhogimanfbhhocjiinjpoidnfccikhogijennjfhlgjclnakhlijjalpneifhnlfnoghcfkggkhanpahnbgbihekkmlegfdglfkgmmafhmaedoadcnmebgpekbhkmmkohloflddoibkmnibgkmfgccohmilijgkmepgkggekonknehiemojlogmdhhplcbidadpilfmfjajdlalnacbmcelmebipmjngoniojhcofilkclmcmiagbeapbilflhbg...
output:
11312224011
result:
ok answer is '11312224011'
Test #57:
score: 0
Accepted
time: 118ms
memory: 3672kb
input:
nbkggpnocokiglglboefodkeegkdkkkkihlbeoodblnnbllkkledolleokkgbocfkfingpnloeekogpdonnlbonkkindggedflghhekkdfoledhknggenedpllnkigkoaokpkgglphlogngdikncopeoikndkegnlkoklidlefooocgkongkociinoogknilekdablklgggngaindgikjnlolggknkhgonllobgneefeidfiookgogololnkkilklbclcgdofooekikkggddnhpccloooddlggeedclnbkln...
output:
11299346703
result:
ok answer is '11299346703'
Test #58:
score: 0
Accepted
time: 117ms
memory: 3824kb
input:
nbkggpnocokiglglboefodkeegkdkkkkihlbeoodblnnbllkkledolleokkgbocfkfingpnloeekogpdonnlbonkkindggedflghhekkdfoledhknggenedpllnkigkoaokpkgglphlogngdikncopeoikndkegnlkoklidlefooocgkongkociinoogknilekdablklgggngaindgikjnlolggknkhgonllobgneefeidfiookgogololnkkilklbclcgdofooekikkggddnhpccloooddlggeedclnbkln...
output:
11299346706
result:
ok answer is '11299346706'
Test #59:
score: 0
Accepted
time: 114ms
memory: 3816kb
input:
fafmjefkajnafaekaeofaabeahldeclkdfhpcdigdjdbfgfgeehocgegfnhlddglhckddoghnfennfkablcifjlcochhdjdkafojgcchakcgjhcabdefcckojbajgjcffgdoejdokbofhkoeffnaneehbjhepjgeckdiaffdjkgdpkaebgafmnifppdeiajccebdagkokcfghbbcdggfeeepjinhfeancnbohpfmflbaaafoghanchajkdmdcciepdhhedpijefieoedgbkfpdcdjfcnpdfhnogfcefbfdkh...
output:
11300860242
result:
ok answer is '11300860242'
Test #60:
score: 0
Accepted
time: 119ms
memory: 3836kb
input:
fafmjefkajnafaekaeofaabeahldeclkdfhpcdigdjdbfgfgeehocgegfnhlddglhckddoghnfennfkablcifjlcochhdjdkafojgcchakcgjhcabdefcckojbajgjcffgdoejdokbofhkoeffnaneehbjhepjgeckdiaffdjkgdpkaebgafmnifppdeiajccebdagkokcfghbbcdggfeeepjinhfeancnbohpfmflbaaafoghanchajkdmdcciepdhhedpijefieoedgbkfpdcdjfcnpdfhnogfcefbfdkh...
output:
11300860244
result:
ok answer is '11300860244'
Test #61:
score: 0
Accepted
time: 119ms
memory: 3704kb
input:
cockoocodimificcffkkcddgcccccoiofdndhgaobcomcccpcchonoikoooffcmfooofdocococbpoocoocmlooohicmchcobjokccccophddmmohpcohocodichockcdkcfcfakohoaococcicoocmnacocfddpcmfnioihmccfcooofmpfcmpbpihomooococmkcooaomcicbdoodccdhcooooccocicmojkkmofidfkofnchkcocckcfoofoicoomcmmoccocbdmhiccokmifcohfcfocadokoihcjoco...
output:
11287058063
result:
ok answer is '11287058063'
Test #62:
score: 0
Accepted
time: 115ms
memory: 3920kb
input:
cockoocodimificcffkkcddgcccccoiofdndhgaobcomcccpcchonoikoooffcmfooofdocococbpoocoocmlooohicmchcobjokccccophddmmohpcohocodichockcdkcfcfakohoaococcicoocmnacocfddpcmfnioihmccfcooofmpfcmpbpihomooococmkcooaomcicbdoodccdhcooooccocicmojkkmofidfkofnchkcocckcfoofoicoomcmmoccocbdmhiccokmifcohfcfocadokoihcjoco...
output:
11287058061
result:
ok answer is '11287058061'
Test #63:
score: 0
Accepted
time: 113ms
memory: 3740kb
input:
agppccnlpacacdjpplilbopichdpaobecolphonnodhacbadlnpnbecaolledagbjhccoacpliihpadnljdcelhdhohaiolhcclpoohollllelhpdbodpllacpdaciaeoihodhhgghjpajnpncpgddcdhogbdoachhplcoinpejjhaconcdajdlpocjlolopgiipepncgcleapldnckcjdillokhljbopaoogonlomkccihhnaocnlcgnhipdkmihoimccljolahppehbhlckhhkdoknpjplejoohdecojol...
output:
11337287002
result:
ok answer is '11337287002'
Test #64:
score: 0
Accepted
time: 116ms
memory: 3672kb
input:
eiieofkhilioaidkldoidcbhddfebchlobiiihobdohmcibldmdbeihhilcebifeicodohiohimmlilialeoliiiimeppeilhhideifdfhlihohbaplahilbdcchpiedihiemahehdliondlcbcliiedhcmhehfiopipbhohdghdibaoidohhelcdbdndoidaedeelddcbiihoihlibdacilhchmlifeicnoecidicchddliiohifhifiloihmadeihieiedileeilicialhelipmchodilchimbdegdhhdc...
output:
11310158723
result:
ok answer is '11310158723'
Test #65:
score: 0
Accepted
time: 117ms
memory: 3752kb
input:
egbelbigmkgpbmcdahjfobeejhfcnppdifkncbjfebbnjacknncdfeikcmnmbaafpfbillejdlgohjnopcobogonmdgfnkpiiakajpfbnakbmcglfnkoopieplkcfgibkhnjogfmhiahgogabkijeipmanlaigkpkelddiglagambmaklmofpmlgnalbenkimjpbembkekmmcjapemnhlcciofjibamdligcblnkbfodmadfolngencnkcpdngdpkihgkgakamjlailkegfkfloflllmpldmikbgddfaddcg...
output:
11250000000
result:
ok answer is '11250000000'
Test #66:
score: 0
Accepted
time: 119ms
memory: 3800kb
input:
idjjgcpcmejokioochickjmimbacdmnhdcoidgjaknmacighlekfnojflabbbhaeejckmidehiacpbgkpigcnhcgdljaebehhnejppbebojblamnffmeiamdndmofgnpeelcbkbhjcmpjcgpoijglhcjnmkoadmdiklcjheoalbfnmejgakdcbkhieidkjfihcdeknhpjgcmdnhlkjllpjgjfppljgniljocgnphedlpdgiidpmejbhipnhfffnkpebblnbaneiblghgboanlojefbpanocihnpiimibcmco...
output:
11249925000
result:
ok answer is '11249925000'
Test #67:
score: 0
Accepted
time: 112ms
memory: 3744kb
input:
dabbkbbdbbbbdbdabbbbkbddbdbbmkbbeeabpbobbgkbigbbbgkegebiggobbkbbpbbmjpdjbiebfakbbbdddbmombbbbbbbbbobdiidbdbeoedibbbaibbekkepiddbobbakbbbabbbbbbbehgbgobpbbgdbodbldpbkbbmibfbgobbbbbbfbjokbbbbbbdobfkhbjdlaobgkbjikbdbbdmkbbdobfmbbbdbbobebdbobbpfiokdbdabodbjblmobobebkbigeefbbgdofbmmbdbkbabbbblbbmbbekdobb...
output:
11249999838
result:
ok answer is '11249999838'
Test #68:
score: 0
Accepted
time: 119ms
memory: 3744kb
input:
dehfpjfjjaeoekjpkolmfmjdjmmocefbpcfipfdiodmabblndifhjhimhhhaljeeegcephjncokglimggjhjeifnmecnjnnoeoddeioilhfohladknpbkbfnebbmmcnlldbkiokloipkdjgabnjepgfokfggmlkimlicceagegofdaggmlnmakpnmgcoiekdkjbnmbodjjgjhgikepfhlklkcoplhjdecdhpcjiofaokoimcfobkheldncpanalfejipfhfieaiaiddioojbhgjfojfimbbkbingnajjnakg...
output:
11268884332
result:
ok answer is '11268884332'
Test #69:
score: 0
Accepted
time: 118ms
memory: 3984kb
input:
fibfnpadfnnkmcbmclbbfghkbibkmhliaombkmpeafkokpogifknmflhogeejkhclocdkbkacepifikohomconocpdbbpkggjolopbbjoppodpeiopbjloegkijhhnmgagbampafobnaoaleifglbkejddkakkoaahibknlpbdkfjfbdmhmmklbeikhjdebdfolmgfnkhlllkdlcncdkcpbmcanoihmlgccakijpnfefchbkogfpboblhgoemohbbfdelclhkbbndejkonjgediebggmdcjicaaeagangepf...
output:
11280292785
result:
ok answer is '11280292785'
Test #70:
score: 0
Accepted
time: 114ms
memory: 3832kb
input:
ejjoaodmkngefceimmjgiekocinjcficnpbgeehkcmcgngmealdjhdjmmjhicfkgbhacjbldigllfnmhjincagepkhaoiobiopcfbaejlhfmhhpommonajigjooddmbafflcmhdjlkiigoobijegahogjkioiaiajigelfmgpgcebcahdbfgdddekdbolbokkllcjhggfnfghmgldobabffhghiolchfioimjkffmiecngpbjpbbmhcdikoilegomcghlbboialcjpiecagllaoeepngmnngipneghhbcepo...
output:
11250244268
result:
ok answer is '11250244268'
Test #71:
score: 0
Accepted
time: 116ms
memory: 3752kb
input:
kbnomlehcjpafeoohnbmpibdkflklefkmdmdeglndekaikkpaeghhcbedpophfgcjbjdalhibbmapfninacgpaoifeocoonopjpfaacocbopldgilhjogomhjoppnhafioomhnbfhapephdohnoiepeokegjmfnkopffnnhjlpfhgmleipflpnacgimjbjjgklcjpnojdfaehhdkjdaokcbnohgkpmaephnjfobejmpmjfpceinehebiadlglmkhakjfihjaflnlclalccjdbegfnnhaglbiihpipjlimfkh...
output:
11251130124
result:
ok answer is '11251130124'
Test #72:
score: 0
Accepted
time: 116ms
memory: 3816kb
input:
ghojngfpncpllmckaohdfekdpkomkgkpijdblkciaiijbcdbfkacdkjgkhgihnoaahkgjhemlnieedemkagoeheghcigjaehljinehpfpeagkohgknlgnidhhnnhamjocjbhfkibebfgdgobjeadmnjpkaacfoepopooepnaojibmiifbhbnhpfhgbmleccgggjkpaomjkeffeaakcpehnfkkeapmcgilagnfoiepofghmjgbmbpebfgfdhdjlanlihmcapigjdeggmoimkmfglhlifmmlnhdipdoeifbgem...
output:
11252676819
result:
ok answer is '11252676819'
Test #73:
score: 0
Accepted
time: 118ms
memory: 3784kb
input:
aeafipbhnfflkpnbklibgmcmihlgonepflbfipnelpfncihjpcgaokpicablcikjnpmlicnnldbkelchlnhimhcipenjdkbaeehcjjgabpjnnhipnidgagmhenlngcmghooidfnhaojbfhnibaedfpfejalgcpadkgdgaeplfnnahepnckepbbomfaocjpmnhjaahonbobabelafhdjoohpilecgchbcpcaaehomlkhigjgpahhhdjbgjjlkllplaejhclkaijmiehiikjamaodgfdfepokpnldenkcoggpo...
output:
11257886685
result:
ok answer is '11257886685'
Test #74:
score: 0
Accepted
time: 119ms
memory: 3676kb
input:
lbggdafkplacpcpipoohgofcefinbimjkacmgjcolhmaaniallcehbijjpdejdcaakchchicpcddgndggpdiogaejbkdbpkjppdeffhofehaicpkkeofiehbgceilhpadfcdimibjimilfdhelmcdlpomlnbcgkfakkfdooelmlgiapccjlpnibkjlhebbjjaejibebekkefjcnffjjdeaonligkgpenlmonaghfneobaimegjppakjijikdopdldolnfmjdfoanhefjhccaknljlooljkkabimnelofkioo...
output:
11250015594
result:
ok answer is '11250015594'
Test #75:
score: 0
Accepted
time: 119ms
memory: 3788kb
input:
lbggdafkplacpcpipoohgofcefinbimjkacmgjcolhmaaniallcehbijjpdejdcaakchchicpcddgndggpdiogaejbkdbpkjppdeffhofehaicpkkeofiehbgceilhpadfcdimibjimilfdhelmcdlpomlnbcgkfakkfdooelmlgiapccjlpnibkjlhebbjjaejibebekkefjcnffjjdeaonligkgpenlmonaghfneobaimegjppakjijikdopdldolnfmjdfoanhefjhccaknljlooljkkabimnelofkioo...
output:
11250015594
result:
ok answer is '11250015594'
Test #76:
score: 0
Accepted
time: 117ms
memory: 3836kb
input:
leoahnpanophdibnldpiablmngaegpfipkifhmacjcnjddckpkdkjajldlnalimabnbbanolemiadccpafciafhghgemmemjfoliogggclcmchjmbdcekoidaeijjnhpodamhmgomkfkkglhljipakpjfjkpcahfooegllepknnoigapjpcabojigonbifomogejfpgalnnpofebflomkcbmdkfapbpaidahjgppiiepboipcndjiejogajimngkfhkoghkhncceplddfmdcacliecbfgmdjbnilipagiklg...
output:
11250088803
result:
ok answer is '11250088803'