Last active
November 1, 2016 15:58
-
-
Save jacob-faber/2bad64d359b1a1e8335a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from itertools import product | |
from functools import lru_cache | |
import time | |
def timeit(method): | |
def timed(*args, **kw): | |
ts = time.time() | |
result = method(*args, **kw) | |
te = time.time() | |
print('%r (%r, %r) %2.2f sec' % \ | |
(method.__name__, args, kw, te - ts)) | |
return result | |
return timed | |
# def is_palindrome(string): | |
# return string == string[::-1] | |
def is_palindrome_border(string, sub): | |
size = len(sub) | |
return string[:size] == sub and string[::-1][:size] == sub | |
@lru_cache(maxsize=None) | |
def count_palindromic_borders(s): | |
total = 0 | |
for i in range(1, len(s)): | |
if s[:i] == s[-i:] and is_palindrome_border(s, s[:i]): | |
total += 1 | |
return total | |
def gen_substrings(string): | |
size = len(string) | |
for x, y in product(range(size), range(size + 1)): | |
if x != y and x < y and abs(x - y) > 1: | |
yield string[x: y] | |
@timeit | |
def main(): | |
# string = input().strip() | |
# string = 'aaaa' | |
string = 'bhbebhbaabhbebhbddbhbebhbaabhbebhbgbhbebhbaabhbebhbddbhbebhbaabhbebhbhhbhbebhbaabhbebhbddbhbebhbaabhbebhbgbhbebhbaabhbebhbddbhbebhbaabhbebhbhhbhbebhbaabhbebhbddbhbebhbaabhbebhbgbhbebhbaabhbebhbddbhbebhbaabhbebhbhhbhbebhbaabhbebhbddbhbebhbaabhbebhbgbhbebhbaabhbebhbddbhbebhbaabhbebhb' | |
# string = 'bhgfdbgfccfdfebccedfagbfegdfedbfchdfabcdeagbehdheheefgbbefhaaafdhaaacddgdbhhadgecdbhbcafhhfahcdhddhfgcdbdcbdfhahcbgddhadgfdgagfdbeaagdbbfcedcecefbabaaegghegfbbgfbgdeaebcbeefhbdabeabaghhdfeegcchbfdbcfddbaaabdachadhhdgcacghfagggchahcdacdbdhbfgcbgbeedehbdecccaebaddddggebfgheaacbegeaffebhgdhcehfacagbfhgdgcdgeecdadafhcfffehceecgeahbhgegahefdhadcabbcggacfcgbeffeehdcdbddgagfachadadbgdddfcebhbfdaagecbhabffbhebceedchhfebbfaccdddbhfcgfddcedggfccbecabgbcebegehbgggaedeafaddgafbbbdbcbcefdbeaafghegdhcdfdgabhgcahfcchegeahaaagghcecbhggcehddfgeedggccfhcehcefadhfgbeehgagbedhaadggfadedaefebgabdgchcbfcaggdggdbecgffdafhfcadcbgadfcfcefbdahbeagggddbdbaadbefccfgahdcdadgacaecgcbbgcehdeceahgdeeddhfghbfadfegdhhefbaeeegaffhabddedaccbhcfehdhgcddddhaafafchfddahgabacbdhfccfaeadhechehabbhgecgdagebafehdgbagfabfedeacebdehhgfchegaeeeehcfhadhbaeeeegbgbffaddcchacdeghdafcaacbagfecdfaecgegbgaahdddbdhcabcadeabbeefcebecgcdedddghhhcgbchecdacebgagafafhghdccggaffahdbbcfdfffchecfehfbhdbcgdaeegbefefhgdceaagheafaacchgdbegbachbgffeedhghhgfhcgedggffeagaghabhbhegdaccgbcfhbhffcddhaahgagfbhecgabcadehegedhdaegdafdafbadhbcdeaefceahdefhafdabbebghbdbcgadadhbhedeechbahbfcbgdfabfbfgddghebgfbdafhdeaddbafdgaagcfahddcbcgdbdeeebdhfecbfcgaahbhbghacccdfbggeccadfhbbbchdahehadahcabedebedhafbbbhacacehfehbeheeggfhdaeeeheeefffeghfadefadheddabcfbfffbbefgaddghbfebbbhbegfhbfbddcaahccdhadcdbcfhggahfbedgdfdeaggbhfdbacbefefhbefaefffbbdeghbgfhhefcfffgbcdhbedgeadcfedbbbachfbhcgbheggfabebfaacadefahgbagdheeggdafhgdehebacbaebeagehffhdagheffhfdgdgdcdedffdbghbedabahfafefccehfdddgfgcadheefdfbhfdheaacefegbedehhcefefbdbfaedcdafdffdhbadabhdggcadafababgbfbdbcaehfhgghbgabcghehceecfedefbfachaggffeeegcehedgbcbfgddchhaaeacebacgfhcbfffebacccdaahddgcdggdaceafdfefgbcdfeehggdghcbcadfgcagefgbadffbgaedeadchgbgacaagfgafeeccgcfdagcacfedagcghagcagafeacaefcchhghfahafddgcfebfddfbdcgdegabbcbaaagaaggdbefgahddcafgcdbgbbacebdebbfbhdfahcghbbdebacdddbefbhbccfedcfcfccefaegbhcchefcaggfafgchdgcgeedggadgechdebcbgebfcgfaehhhgcfcgbafbedfgdacecddgeaacfageagccdeaefffbbchecbaefdcbddeadcfdahfeegabdgceabadcbhhecbaffaahfeafbebhecdcehdfaghbfhfhafefgfedbeacabcfdfhheceeaefgddfdacaghecabccbeeghbghgadcbhahcdefdgfcfcefdgaecedcgbbebegcegbgbgefebhcddhgbhdeeggchhgadedhdegeccbhdabhdaffaabeghgfgegbabbdfhaabbhecadfabcabdeaccfagdchedcccccdebhgbddbegcfbgfebdehgggdbbfddhghagfbbbcfhecadaeedbdbhcebdbegadgabdbceehdabedbahebdgbfccaeggebefcageecdadfeggegdgbbhgdbghheebbbdbhafcdffabdhgbcecddageggddceedafcacedabebfdhgfdbagbgcaegdgchbceecgaggccahfhfcdgcbaaeafcddecfhgbbebhddbdcgcaafgchgddgafbdbdaabbcgdbbgdebbgbcehedghgehdgdebdfdfhbaacgdghfeahaaddgdbcceafbcbgfgfggfaebgegcefdeagcdafgefdfhedecacagcfhabfdfcgcceegebebhhggecdgcfhaaehafedcgbebgbhccddbccagedfgaehaagbfdehbgecefbghecbhebfaecgegffgegdhcdaahdeeeddbfeabffbbahggfdfbbaaddaecdagadcbagbbegcfgcdfhgcahcadgahaehhedbfdhgfdehbdbeaadcaceafcbedfecbhdgccehgahhdaddbgfbbccgeddhahbbgehahdafdhehhhcagachcefghaghhhafehgdcgaffeeedhfbhhabdghcgfbgfbdbabecheheaebddgfcffdadcccadafedgefcgegfbgbcbeaggfebfhehbecbbgfhccbaghfhfhbgdbfcgbddahccdedecadeceebdcaabchedegcfcffbahfedbhdfdgbahfchfdbehfaghfaedbecgbfaabfdhgdgdffbahfaeggddghghebgfggfhdagbeefbcgcbdcfbaafghdfdedadbfcegbgcfddhbfaehfghfdffgdadgbgagaeebcghfcgghhdhebgceehchhffadfhecdfececedadcdcgebaafhdehabhehgabcffechafadhdgfahgaefdaeebeaacabefhahgaegedccbcbhcfegfbcgfchhcaehhehgfdebhgdaaehdbdbgedebfdbhefgdbfbgbghaecafghahcbfhecabfbabggfaeggfegfbafgheggghefdggedhefgccggaedfcagdfecbcaabefecdagdedbgfhffdacgbabgedagdahafdcbdaehdfgaedghdafebgdfbdefddfahhbcafcdcaegdcggcdddcgbdbfaeafehfgcfdeageeehgcfbgaeagfdhceddbacggedbaeheaedhgbaebeeacaheedhfdcebghchdcdeghdeadbbhfbbfbgbefhhhdagccfgeacchfhhaabhfcbddhehedgeggcbbhhfhbahghgghhfecghffefchdggcahdhgaghaffhedgdadfhcdegaggdeefedadbbcabhfbdahhacehfhedhcbdhfadabhbcbbdageegedhghgdhchgfabegchgdgafhbaaafegbhfhgedfgcedcfhahhhcfhhfaafafbhgaefgaaehcacffcffbehgdhdehaeebdcbahaaaehcechbefgfbgdffhbehfabbccbbcbbgbecddehacecahhfgabgfbhgdbhfebgcccffgbegdaaehhbghdefeddaedfaeddggadebhcehdagccecfahbdcbafgabcdhadceebgbabbheddgaefchhdhfcagedgehaadcgecagbebfccbheaghadbacfdabcabgcacfaagecdgeefafdhfhbfbgabadbbbebdbbehfgddchaceebbdcgebhfbcgcdcegdfcddaggcfhecdgdgaccbbhcdffgabedghgbheacchgecehafbcgcbbfggdghacfhahgfhahghdadcaaechgdaebghafhccgcbfhafggebgaegaaahgdhcffcfcbhfabgfbhchfhbehfchfdhdgggdeaagbhdbbcgcbbbgacchhfgeafagegcagcghccbdehffagdabghadgfddfbhddhbggaaabdebabbgechcbafhfadcccffcgdagdaagebgfcfbeeegebfbcadedabfgfffaffhbgfgachfhdddfafhbadebebhbgecdbbehgcabbfafadcaabbbefcagbcegehhfdhdfheheeeeageahgbddddcffgdbgcgbbchaggedcadafdhdfcgafafdhaefddgefffddbgfcbfhfeccgacebahaadfdgdadbfhegfcahhheebgccagdafdbbaehdedebcbahdagcacgbabdbhgbfbcgbhffdabfccfcffaafdghdhcehbgecacehhbdacacffeccfcaabhdabahcgdfgfbgfcbfebhbgeeabgabhheabehdcdababhfdacabcbhgfhheaadhedabdedgeeggdebdgbeaddgadfedfaccdddghgedddbghdcfegghceafceahecbafegeddaggbefegcbfaahfaehfegbgabeeaahdafbccggaahfbaegaaffedhddahaahhdafechcahdafeabcachggcfbgfaggafbacgcbacbdcghchbdbabadgbbdchbcedchbeabgbfbhedhggaghabfccbebcggfafgefachfdgbhfhfggfghcacdedgcbdcgcgecbdhebadhabfggdfaeheadcdeffdhehbfcabdbfcbghhedeeheahhccdaaghefbbhbcdchfdffcbahghdggcbbfbbeafbbgbdaefabbfgdhgcfffdehefffgbgdchbdcbhabbbhhegghddeghedebaccgfeggaaahababaagggfbbbabfdfgdaacffaefaeebffcgfaedfgehgfebddeddgaagefhacaghceedahagdhebefehchcahdheagecgcbagfdheefadcbhhfgbebcdebhehehfgaffgbecfbcaddadageehgadhhagdhdchbhfcdahechaghdgghdfgdbfcbegahahahfccfbghbgfabegbhehcfeegacgacfabcddhechfaegcaedhacbfggdhabhdhhebcabhcaececefhhehbgfaeahecghbfecaedhgddaagfffebeghbgdcfaedhfadhahdhfgdggbddghfcfeedagaacdhhedgecbeaahggabcgahagdebdccdefddbgcgadcadbgcbhehadhggehcgbfdhagagagheahhbgbcffbfabdhfdbdeggdhfeffcebdebecchhaafabahgdacahadgfhddcaefefbgaafabcacdabgadghdcfbbbedbaafgcdgcagddgggghehcdgffeggfccgdcdbeghhgfcbdahchebbhhhedfcaaegdhbedhdcgafhdfhffdggcgfgbdacdfagecchbfchfhhaeggbbeadcfbeabgdggbcadccaebfdaghgebhabcdgdhhffcddegehagaehfhadgghhgaaadhecgbhaececgeceegebfefecedaeebhdfbbgabcdgfbchgggchdgehabdbfhcfchgdfhehccedeebccdcfbgfchadfhfcbeaebhaabdffhbgcdceadcffcfahefbfbbbcbcdcfahebggeacedfcbhhbgehhbaaddbfgecgdghbfdbhhfebgdbhbfgaghbbccgagagchfdeafdhcabadchfhgfffghhbfhhgfbfcfbccebeeceaedfdbcbgbafcfebdbdadabfcghgcbccgfhbhccfdcdfahgdbbeebfcddbbgcdaabacaceffhachaacbcgfdehhhaafdegdfgffaccfbdhadhcebbbffbeebeceaaafgfcghfdaacadbdhdeaabbefdahhbhhgffbdeggfgafbcaafeaffcbdfbceccebhbcdfabcgcaheahbfhgcbhfgaaddchebagefggaeaadeacffbdadcfbcfefhdbbdhfbfdbbdbehbgehahhdbeeecbbbedcacabadcbhdggeeddeccheheabfbcbefbhfchaeahhggedbhhdchhbdhcabebfbdegfdhcegbcefffffbheaahachbgagaddgbgfdceefaccghhhgdhgchabagchgfcfgacbdggahacfhceffddaddbdbdcabefhfhbaghafhccgegdcbgcebdachccahhhehaefhecggeedchfdfhagcabbcdbbdbfcbbhbfbhefehhdecbdchfcahfeaghbebdfaedbdhghgfdchefcdceebbacahdeagbacebgdhfbeaddeafadceedegddchdabddfebbdgchhgcdgadbchgfdebggabhbechadadbccaafehfhahhgecdfbbgcahhcghfgdhbfhbcdahdbgchdecafegaeghhegedbdehdfbggbbhhdgcabdffbfbheaedfheadddafcggdffheahfdececdegeabbhgbcbfcghbecgcbccahffbbhfffbfhcefdggabfhcbcadddfeccbeeabbfcheedbhcaadfhfgbfcfahbdcchgcahhcgegcffeffhcfebgbddccefegecaecagaeecbbghhfbebccdfgfaccebghbcbbabfeehfcgeahabcdehbbhddeebdgdehdffhbefecbebcfdfcdgdcbhggabeefdhdaheeeagfeahcdeegchbeghchbgdgbcbcbggfgfddfcfahbhbaafhhhgafbhhdabfghcfefabafchgbagbgfafdbdeacaadfhchehfeafbcehdefecdfaggddgfdgaafchbbefcbgeffacdeegbeehhhfeceecbhcdagacahhfehhhdeffaceabceegbghaacahddhccegbegeadbafgahafdggbfgcagbdbafdedeabbafcbcabbagegegecaebbhcbegfhcgbdggghagbchhgfeebgefhfecgaaeaccbgaheahcbbbaaheeadbgcgcefdebdhdefddbdcdeeffeebaeebchafdfaagdhbheecfaeaeafbebdfghgaggfcdfcbabchfhbchgcdgafdbaahhgagffaadccddedadecccegbedegdefccfahdaagccbfgefcbhedeceafagaeedhbdgeegcgaeehabbbbfffabffceggabfbeegacahdedcfedgfadcafagheefefdfbhdcbebeaegfabegchaceaadeebabegddbfefgbgchdcbhadhbfdbghgcageeehhgeddcebeefgfehadafhbdghgggcccbbafeehbfdfcbchaccahbcdhbbfhdhceacbfgageddgefffhafgbhbbbcgafgcbgfcddcbhfegcbdhadehfeagfdefacacbfeeahgaecggebfefcdcgeadheahhabafgegfcgbfeabfffchbeffeaebbdabfahdefahdbehbfehchgddeaaeebfabhfbgafdaegbafdfbcaaadeeeebafgagffhdfegfbehbbchdehdechbgdchaahggffbccaadehegbdbfcebfecdhecafcgdheebgebbbafhbbagdeaaaceahgaeaghhcdbaacbbdhaeaaddedeffafegfahdhggdhgdcaefhebheecahgffgcbfhcedbcbechhehdbghcfdhaeggbdfefcdhggaahfcheggahfhccdbchhbadgeaaahgghggebfbhdbhaabddcfcbgdeeheehdcgdbehcbabebafcbafdfafedbacgfcbhaeaeecfeebgegaggfbefgaaaadgffhffefbaageehcagcgeaaafgaggbbeggeddabeabcefbhfhbeebeehcffbggfeebahbbdbcfghgfeggacaeghhdeabcfgghgfahacbfaadfebdfddbccafgahagfgfddfcdhdahdeehfaebdgdggaehhffedchhhbchedghhdheddfgbaeabbhagefbgeafgdecgdcfgbbbehhghegaffbdbgehcfeaabdgefdcgedcdcadggdddegecddfaafabagffbhdfcgbegedfhgaeffgaadaababbgghhfcehafehbhebfefcbdcchccacebacahadehdbdcdcgeadbceefgdhbdcffchfchaghehcgcffgfahheeedheedgbaaafcagahcabacgfbdfadcehfedbhbchcceeccfbefdfhbcafabacfhhbdaaechgeedhgaadfdaefcfccgcedbdfedfbffhcbcbhcbchfcecfbehhgechhhedffacecdhdcbffbchfeegaefgahfhhbcegdgdfbcbddgaeaabeeheaecaehadbchhffcdgeebacceccgggfchcehgdhbecaehfgcddgedaghcafahdcgfgfdcfeghecgbbbeehahahgchedghfeeechghdeghheaafeefedfdbhdfcbeagaeahchcgfbfbbfhfbecebfgaaddcadaahaabhcheefffcedeafabcgcdcffcafchfcaefhabefghcbdcgdebcgeedbgdgacddchabhbgehfgbabhdfafdebgfhbdadgdffdgeeebdbhebaeffecabeggdhcdcaghgbgcfcdbedffdbcbgfbhbafehhacagbgahafcegghedcfgdddfcefaaehaghhafhhgebcdhbhddebhaeecabcafcbebaehhdfdfhgeafhdcaccegeehhffbgbcgfbfagaffhcfebbgcdagcfdbeagfghheebbfhbcfaecfgddahegbbbcfbbchabdfceccgehgbbdhfhhedffehhbaadabedghaabgeaefbaeghdccbhgahhahcaagegfeggcdggaagfgfabhbafbhechgchfggccebehhdahbfghfhghheahacghffeddggahchhfhgheegcdebdabcbeaabfeebccbcfabcahbeehghehcebeffefgcbcdefegceheeggbcfhcbhegabdffbdhcfcgcgeeddbhchaeeagghdehehebahbdedbhcgdfbeeddfaafggebcdfbhhcgafcdgbfefcgbhbfebfbadfbfahghgafgfhbebhagbghaaeebbfbecdbccabaagggghchgcfabeabbfcccehfhahbabbbhhhfgbefdbfegffhcabfeacdbbebcfccebhccehgfecdcaceaebeedhffdhhabbedbgffgdccggegabgeccbgbgdefceheacfghcedehbcdhdefhhhafahaeecadgafdgffdaccbefahcfhbehgeggadaaghaecgbabbcdcgbcgdhfedechdahgahehhacfbchcececdgagffcacehfegdffheeagcbabeedahhhhfefafheeebdhgagcfgbhabaegdefcdeaabafaebefeddfcgcahbaabegebdheahebhbcddgbhceeecgebhfcabafceeheddfcfhfagghadeefcahcfbchbhbfdabgehabggbeeaeheafhbebgfdfgdheghffdefeddfhagehceebfacefgbebaahafedccafffefdafgfbhcccghaadbadaabfedheaebecffhdcacecedcedffdbgecdafcefgfbacghfaaafceaebdcggdecfhccbghaeaaghaehaeecaehbhbageeabeddfbcffcgebgabgefaechgbaghecafgdaeecbcfhggfghdcfeghdeaecaafagddghhbbbgahegfebhbfgabcaffafcadfdcfddgebgefebbgbcdhcebdbgdhaecghedchbhahdgeehcfcfeecghdedcfhfdgbgbbhabgdhchhefbcbfehfheacbhhefacgbbgdhbccbbggcahaehfedfgeefabfcahdgccaeebgdhadgaaffeaccegheaegadbgfegcahadgahfbhcgddbfhheehacheegbaedaedecedhfccdffeceegadgddchbehfhhbddehgdeafhfcehhafhdecggbhcafcagfdcecgacdhagdhfdfehbhfhafcbcebabedfgbfbeebcaahdfecgdagdfaehefhfcccadhbadccddchagbhbbfegfbfbgfgahabdhcdcffgahfafghgaedgbeeccbadaaedhggcdeaddfebddhdaccbggebheehfadegbgcfgfbdbchfbcfeegcccdbhhbeheagfhadffebhgaehcbdhhgbcbdbbefaafgfegaceeddcdhcfafehdgbfbcgfhgfffcbdddhhgccbbehbbdbfbcccfahegebdhdhcggbfbdgchfebbfgchafeaebgbccafbcehdbahhdgfhhgefadffafcbeddgdbhffgaghhfcgcbfafdbaagagabcdfagghddfebedggbbhhbeccfcbfabhcfecdcbhfhdgdgecafbhhgbbddcaeehgbdbefcdcbgafffhfcaebgfdbafcebbdcfehcgcfabffgcedfehgdebeehgbaaedfachgeegfcddehgbefahbbdgachbcdehdggbcdaafddbdcdhhdgbebhfdggfbceeadfcgfcdbgeeahdhcbahchegfcdgeacedagbfbeghachafgcghbbgfhehccdcfhffggchcbgddfdbdfhchabehfechheehcbfaeedfcgahbbcgbffbgcbdgdcfhhebabceffbhdcgedbcegagechhacbfbacdbdffbchafbhbeadbgdhcfgbfacdbdfeeabbbdacabbbgbfhhagbgecdeegfhdcdedffhfhhhabfbgeagcbegdacaghhcbdgfadefddedebfcffbhhffcfhcehcgafeffhbccfhgbadegaffhcdcaceebgccdghafbdagcghcbdabagbdbdddhhfgbhbhgcehfefhcfbdacfbagebbheagbghaaghccghhegbbhfbbccbagcbfhbdaacbaaacdgbcchddgafachbcgedddfhdfbefcehfdahfhcbfdgfffhadddhgagbfhgcbcbgfbfdaaegdcdahcadfecdeafchdebfghdhfgafcgaebadebgbfafbacdafabcgafffdfcfdcbfdfbedcbehcebgeggfbeggbdchghcabhdgahbdafcdcebgcheddccefedddgeefhcghebhbdcdhdcccgffahcfdfbhdfdbeghdcadddfhdbbfdhcbhcdefafeecafhgecaefdhdccedhhccabedgbedgaggffebheffheachefgdaaebehhgddedbcaggbfcgcbdcdcgbacbbgcffcdbfhegbfehgbbfedaggcfhchadfdbcfedceaaffefdfgabbaaacfhfeaabdbdaghcchchegehddafeafedceageahhcchabbcadbebgeebebfegchaghgcafbcaacbbecefgfdcbegdcdbeccccaecgfegfghgcbchahdcahbdbeffghhahdcfagdfeddgefgeebhfaaacefhcehdecfbdefaaaehebfbggadgadaebagfhbbbhdedafdabcechfaffdefhebaeafdbhfacbdcghchbgcbecgbgchfhafdachcbecdfgfefhdggfhcagdgacdhdaddccfegahdgfhdedbcabeahaghcbhfbcbeegacghfeefhbabdacabbahacbhacbbgfhghggfccccdcdhcfhdghdgbegbghcffcdeabbcedehfhgaefdcegbgchhbgcgdebaedbghfdgccfchcgbhecfhbeaaggdchdgcffbcaaecfhbhfdgbfdahaahggcbgghadecfecbhhaagfdfhbahaaahhgbaehhfcehhabbhabaghddgeefeefddefdaedfhheghfhhfbheachghdddabhdfehfacdhbhgaffhcggggbgeabadbbcfggedhggghgehdchfafehgcdgddcfeeccdggceeadcfcfhbdhhhgfbceefgbccdefbchfhaabfdheecddbcbcefgbdadfdadfcccbcddhgcdcehgfbhhfefghfcebchgecagedbebdhehgcehbdefadegfahhafdcfbgbcccfcgeaaaabdegehccedbddghfdadedghaaffagfahbfgfeahbdaeggddbehghffhfcefacgaddgahghachfafaegededabdfehcebaeedcedbdddcadhbhgfccbceehadcefcbbgdgbebehefddgcbdfeehaahaebebdfcbbacfchfgeabccdfhhchhcghghdhcbceccghefecbeedhhbggdfffdeechdfafbcahcefghgddcccdaaggfdbbheadbbacdabffgeefhhhbbcbbahgdbhdfhggagaehbbeafafehefaghbgghbhgeefccgbccaedeebebfdfdddcebadcabhegbhecbgcfcgbdccafhdacfedghggafchgbdbdcdaeccheehcedcgahcggaehfhgdabeddaehcgggcgagbdfbchaahehedfhehehcedcgbaeegfchahbcgbcffcbbhbfgfebbadhbddfcaabahccgdfdbhfcgghfddgedbdfegcghcahcccaghdhgabegabbdhfhaaefhgdgbdfdghdeggdehebfechhcegcfchebdccghfehaafgdcfhdddfcdhgbcdebhfebhdbehaeafcdhadcdgafbhddbhhdgehadcbhcbdcgffgfaaahafaabdbaceggegbghaaadchbafgafhhgeagfdhfgeeeacggcghccbbdbgbceabcfbacfhaddehdgfcaebdgcebedcghdhbabbcgacbegahfgbfccaaffbbadhhggaghbbfbdgfchfhfgehbfhgcahcdgbcebaecbbdfabhhggeecdfhcdbccdfaehffabhbcdgcefbcdfggaefchhecccchbhebaeddhbfdhhfcedafhghhfebhgdghddbdheggfebedghhbhebfeacabcgeafhdgdccbaafbeahdabdecaacdadfghfehbccdfdefbfbbffbgagaagcdhfafegbdhefcbbggcehdbefhedhfbbaagbgchhggddaeehcgdcceghddccaddaebbcdabbgffhbbgeabgcfebahdchgfacgbebcgdadahebfabggdddedchfcgccaadfcfdfggffcgddabbdfeaahhgbfadgbgddegacefhgdcbdedhbhhbgghheaccbbfefdehhbgfebhafchgbghaehhahccadheacahbbfhfggfdaebbcbbhabhhdchgbdgedffecebbchecdgeghffhgegbgfhaafedcbhfgagahcddahbheggdceebbebbbfeegdbeehfdbagchhbdfagaedbghchaheefhfcdehhghfagfbbcbacgddecfdcehhcheecbdbhchhaeabgcbbaeeegchbghaageeafhcebbdbfeddgeegbbchdbabaacgfghcgbhhccbhgeceahcbaebdgbegcgfhfebdfachddgbhagahabhfccdehbgfgfccgfhhagcdeddfbdeceehhgcdfdbdcgfeededdcfghbbeceaebedadfdabeddcbhgedchghffahbddbhegdebahbbdfefgeechgbffgcgfdbbfafddceebfffcccaggcfeddccfahbbagbgbfafbbcggfabfghaeedhgfegffhfdadefdbgfefdbfegeegaachghdeebdcedfbbbchggebhcgggcegcgfagaecbhegcchddbdbahchbafhccfeacegdabehfcchbfcdaddagcbgabbcgfcbcbeccachdehebbhcfccdfdbfechdabeccaeeagedcdaeehgbcaehdgeaaddaehchhhdhfhdacdehccaecfdfdhfdcaehhgggfbgdbbddehcgbdddagadgggagchgbfeghcbadedhdggebbhbhaefgcgeffcgdhecbgcfcfegdccedcfdcbaaegebehhhgdbhbdeeabcedeahggcahcadbfefedechfbaageahgecdfbbddccgcghhcedgafffhfffcfeacgdhafcdhebbcabfeedecabbfgghecagadfaahehdfbggcdcgghagabdhhddbdbcggchfggaehgcbbeahdafecbdbegdhhfffhecgdcccbeecaeceehagadaebddaabfhfhfabhdcdhfedhahgaghdgdebhebabafaggbfbebabfdafcgfafagbehaaaabbfbhdceegfehchhhcgecdebeaaeabebcccbfffcddgdfgcfaabcegdagefhfbahddabafddabgghbdhbecfcfgbbdageafadfbddehdffbfgeeabgfdedefgeedfbdaheecadffahchdhhefeabaehgbdbgeegdacfafdggcaffhecfacgagfhhaafffeafgggebecdehaedcbdehedfdcfdacaedgcbegcaafehfacabgebchgfcdacgbgbhacdhedhbhhgabgbhdcbcageehgcaedhffcebfdcecaeehgdcafebdbfchhcecbbhdfaaacfdcbhbhcdahabdbgfafaehbfgfcgfdacgcefedhhdhhecachbhhfgbdegfcdacggfcdbfdabcafeaadbhdhgeccchffahdgefcfdfgehgbdgbgabbhhfbbhagfagahcgbabggffegacagcbabafcbfdacdgccaadabbgggcfgfffhgfbgcdhhghbcfeegeaggbfeahbgegdeeafcdacchbebhaffefdchahhaafehbadbfgegahfbdgaddfhbbcabbhbbegafgehecdccchdffeaababccbedafefdfccbbgdfafhhafeefegfgahhecachffehhfbfagfffefcacafafdafcfhchghechehabhgheddcgeegbedeeagbabagafbhbahcafbebfghbcfcgagdbeebffhgcafdbffbchfdeecfghhfafabbechbbfdccgdheecdbfhfaeehdbhababfcahefcgabbhffbaghhehdaggbggcghhbagffbdfcefhbghhfgdebddhebfghegaeefcfahheegfdffadafeeadabahaffbbbgdhhdgdhfbccgdggaccagdbgcbdhcfabahadgdddeffcadbagdaegbcadghfdagdhghfccaghgbabcahfbdecgefeedhebcdabbcdbadhbdbddabeefhcbegfhfbbhfbbgdehdhhfcaagabcegbgageffbhgbehcccgbggadaadgbfbfdcedaabgcaedeefggdhebahcadababhdedhedacfahaedfcbbbgcbfecafdagcecfdhbdbgdahhdebffcdaeaegbbbbaefcbabcddbgdafhegecbhcfhgdaaecaahccaeedhfccfhbcgfehegeeeheedgeeghggdcbcadefdghbddaabeegdacghhcfgadbdeddahadfaebdebfafddffbeeebceedhbgcbgdeddaegefdecghaeaeaegdbcgadfdedgagbadheadadbhdfahgefbfahgdebahhagabbhfbcgeefhbfhhceaheafaegaefacfbdfhehfbdcafahecefbafhabfafdbhaccfbhfgaabafbacdeheeedffbfdegcebfccehbehcefdehgagcfcgchhhcdgfhhcbbgaccaegfhdefdcaaegcdfcgaadhhfbadbdfbhdghgceceecacfehhchhfhgcagfbbcdbfbaeeegababdffdehcdebbgbaddbfgcchcgdheeaffdccghbbcfcedeeghfdfafeceabaebfbfaddheebbhfedbcchfhhcdbgddhheeabedfdhbfaacedegfddecgadedgdddadeehbagdfhdhdhdcegfbadbeaecdhfddcacdaagfhcedbaffgcghghdgefbddfgffaafbhcabgdcgahfdgebfhhbeafhfdecefhfebffabhgbgdeehfcgeddfaccehfaeefagcfgdeefcabhhhbgdebafddbcabgeggcadaehfbcfcbebccfgdfdhaebafafdghecaabfbdcdegfgbcfehadaffacffgdfcffchcdceghcdfdfcafddfaafcfdabacgfefhhadghfbebhhbecebcfgecbfdbhcgehfdhabggddhccageehgbfcehhhahbhdbegafahddccfecdagcgahaegadhhfgcgcaghafcdheadgddffbffcbdcecbbadhddgcedfhdbagadcfbdcgfdbhheabedahhgcdchcfacdagffhbhfgcggccgdhcdgbcaeehgbabeahcggdfdbabhcegfdaabbccfgbdhbeecdgabbfecfgchcaefafgbhaggcbfdgbfbhfdadhdaffahfeefbdgbdehffebdggffeaghhbhfghedebafegghcffhcgdaeafaadhhehecgbfccfagdgffecfgaagfadfahfhdeegcfdfhbffedcchfhffhdchhahgfgbbchdhdagefdabgcadbgaabdhadggafabhhehcffgcbhdhbecdccddfdeabcagcbgcgfedcdfdcbcdfeghhccefgfgbffdhdffacacffghgacdfbcedfaadfgeddacgfhghhbeehddhggehbacgbcbgagbegdcdcbdbchgbdbabhfaafcggeafeggaecdheecggcehffhgeegfcadaedfabebfgefcahagbefgbeegbcddcgdgcbhdfabdegfefgchchfedcceefhhddffeebbeceaabefhgecfcgbeafaffhaafgebhfgbbgbcdgcbdehfcabcfbhcbhcgfghedffeeghhfbaafhfhhgbfhahahcgfagbedhahfhgcahcfghegffdffcffeecfcdbfcbfabdcbcfhbedhcbchgeedbafgcbhadafdbagdddcehfdbgfafbfacfgaahhacafgbfeeahgegehaceahgfaadgbdfadhaafcfbggafchbchdghdefdfabgdgggfhgdbdehbfeeefgdbecebhhghaecgcadbggccdcdagheefhfcbbdbabaafdghdbbcadedfhdehhaegfghgbagcbgheehhfabfdfabfdfecfaachaaaagdbecfabffbgdfedgbhdfbafcceccfcaaeecbeegbffecbaachdhadecfbehghhgddaehedbcafebffdeacfeghbhebfdadgeecdafecfchghebeedbacacbedhhdcfhgadhfhbdbabbedfbggbagdcdgbccdabcaebfecafdcghfdadbceafgdehfgcfhefefdaadfdfecchdgbfcbcaeghbebhegeadhaddfgabbdbebcbddddhccagdhcbecfdcagahhbaccedefghabgcdhbggdacgfgafeaedcefeaabfgaghhacgbbefbhdgfddbeafgeccfddcbeabdbdbcefhfecdbghdchaadccafgdhcdafedghadgfabbbhaebhebchddebgddbdaghgfhcdecefddfaeeefhdbcacadgbhghgfefhabbeheaeeebbcaedcefcaddhcdfhhcghdhecdehaaabcaffccdecghbacghcafbdefgabfacfbefgchafdcdcdefbdhbbaffgdfhafbfggcfabffeaagdedfacgbddgbgeagbcdaaffagcfccfbgcedchbdcfbddfdchffhfdefbgcebafhcbceadhcaafegbgfgdeegabageehebggcacdebfebdahegeccagaaaaheegaffgafadbbagcdgchfgchhahhaageefecccchcfbdfhgbfaacgcbfdbfdbdafaehchbcbgdfecdfhdfcbadhdeegfhgdadccceedchagbddbgbdabgheddcacbdcegfgcbbebcdcfgdehgeafdeaghaaaedecacebdacfdfdcahbhdceggeefeefahbchdgbhhdecahebggabaehgadeeabfhdhhggaffdchebefacfbcbbabeefegcebcdhadffghecaahacecefdfghbeehgaaadaagffeechecgffdhbacghbadfhbfacaacgfadbccfeacbdbdedbdfbgcbhabbabehgechgeeceheaaheeahbcfddedegefcddgfcebggffcfgbbccadefghccdagacbdagfehdcebfchgdbaeeebcddegdcgfdbfbgbacefdbhchcdagheabadgghafeegcffdghhdcaceaehadgedhegfdfgaccgehdhfchaehcahhhhcfeffadcdbaddcchcfghafaefcfebeedcaahaebefchaebhghfghdgdaaaecfafhaggbchfhbehgggefdcegahgbaddfdaeegcfabchdggbeefbaafgaffbfaecdfghdaeebgdefcfbgddgdafdfcfccbefgcfccbgeabafdggcbbaecfhhhecbgghebegdfehfgacbgbdhcedebcebhgcfebbffabdeaacadegehfgdadfdhgcfahbcahhaacfadhbgdhcdfagfddacbchcbbecadcaghabhbhcbbfgbedfhehbghdaahcaceaaeabdcafdbdbdheagahhhgchgbbgefgebhgebgceaffdebdccccbbeahgbgcgegadeeedgaddfghhbcbdeceacegdcabghbcdgggehbaehhdabeefgagaeedgfffeghhefgbehbbhaehcbdhhefaacdhhaedhdcdaaefafghgcgadchdgfdghgfghbbgedbfegcedadbcbbgdbbbgeafcfdbhehdhbadhchcccefefdhgebeabbcgeefadbaebddedggfcdbhgbgccccdefbabhbeabbbeefhcefehgeghcabedeaagbbfcffdgghdehfaechcgfcagdebafbggcdahadggcbcbgcfacaghcgffdgfahdgbggbgbhfdahfgcchecfdeebchhhhhdfabdbaeafhaeehghgcbdgghhagghffccgefhebabbaffheefggbeeadehcdehghfcefggfhhfeefabchhdddehhdbchaaggcddabahafeeceffdeahhegghhbhhbffeaaebaebgagaedfaaghhcfgcehbdagbehbbacfcafaabdgbdeadgfbababfaagfhhghbdbbabcbfadaeddcbedceehfefcdfadgdeadgcedchdgdhaeddgaagfedhaahdhchhffbbadbebedbagfggfedbacbabehdegabhcccdgdhbfhhcfghcbaceccfgcbcabeadgcgegffdeefcceeeegagaffcghdadddbfcfdhcgehdgbhcfeafcadhdbhgbcbfeghbcgeacdeaedcchchcdcbgeaefdfchdbafaegchcdeffgfafhdaabebfbecedffddfabahdddaabfahedhfedgbecdafbgaedafdaagdahfghecddhhgfbchedefbfbefgafggbhfgffchafhhdeafefaacbfegdcgabebachfhbehgdgbahheehegbcchffffgbhgdgdcahbgdaadhhhdgdbhfegcbdahfhfafadfheeceefddegbaabfehafdaeahbaebdcaagdecaaffggfghcchchccdcbecgfgagggbcabcfgbddhdgccabedfgebachgcfeaghahbfgcbbcehegafcdcaheacdheadfgcffeddgefaaeegecaheahaabdhfddcbfahbdcahhaheffahfadfhefahffdaaefadhdghcfhbbegcddchabdfbccgfcgcagfhbdgdbfeccceffgefhhdacfhhafbaehhfcfbdcfgeaccfbgdaggbadahdfbdbachchagcfegfgadhhgafebfhbedgfgafbhaahgcecbcabfaadafhbcgchbaeaacbhcbgaedcffcgcchfceedhcfgegcegefgggegchahedggffdabhdacbgghbcffhdefacahdhegfcdcgdefhehadfhehebgafeaaehdddbbgedeahbhebhhggdgceeccaccecfafgbdcehcebbacahagcgbgddadgcaahaffbbafacbbebdeaedccebfhbbfebfdbdbcebhedbghcbedfhfadgfcagaehfhaaacebcbfdhefaaaghggcedfecfabcacdaehcgahbhdhaehgdfegchdgbahdchffhbfbafabfeafaaddfhbhgegaefdheaedbbfbhfdebdbbdefbdgabdgbhdegheddgeahdfchhgaabefchedbhbcgfhfedahbehbafdhebaedecfegaffchdhgadcaddfcefhaedbeaebccfaccfebadabhcbcfgecdecahdehafbccbeegbghegadabffachdgbdffafffghaadegecfbafeahcghefcchghegebddadddabachbdefddhbcdhffgdfcbbdeedahgabgcahfefbaeccabhfhccbdeeaahaagabecbeafbbffdaffhdecfgfbcfccfcafdeaeaabbbhhehebghgafegggdaabcagffgbfgdhhcgebcfhcdahhgfgbggcahbgehhbgcafegbfbhfdcfccdhaefghgfaebhddfgddcceaddfggcaafhabfgadeahfacafaeadgfdbaahgchghggadfbgbbfgbahhadhdbegcfgbdaachgaacfbagcgfegedghccahacehdhhdbhbchdhaegccdgahbggeagdbahadghgaghcfdbfhhabcgbbahheafhbfgbaeagehggebacahcbcacdabdebadcgbdggefcddbhebbeadfcehgeabbcbeehgageedghghgcaagbdddhcbeccfeebbdhbbdfececbcecccdgfgfhabccgggahchaddfafbcgehagbdehccgcdaechdcgfbhaeeabgdaccaadefcghbacbeeahgheagfecfgaagccgdgcaaahbabdfgdeecbeagbddhdefggdbegbfgaghbbehfaehbaahbddaghfefbfchghfgfeahahebddcedcfgfgfedbbehddfcbeafehgddhhgbdcdaaagfechgggbcdedheaddghgfgehbgcbhdaehcdfabhcfdfehgacehacfebgddhcghggbcdcdceafcfeafgeeggbdhhgdgabgghhadbefgedabhaggeceddhccffbfhheggebaahgfcggbgfhchefddafbfggefcdeheehdcefadhgagahcgcggahdgfaeadahhegdgdaggheggefacagaafegdecdhccggabedccbbghhdfaffggfecdhggcfaedhefdahgbaebahgafdgdacfdbdbdachdbeaeehcfahgageadhgghbddcgegggfchbcefcgdcfbcegchfagfbbaeaecgdhacbdggffbhcdbgbdggdedffdbfadedcefdhecebdddgechhagdebabfbhfedaghfchbedchhggdafdadgefgfchehdhhbhedgghbahagfegchggfcddafceefedgdhcbfbcgadefhdagbgdebgegaacfefdhefachdahgeffhfdbdgfeebcebebgbeffcghbbhahefedcheffbbbcdfehgcachgefffgfgfbdbegabdfcfgfadbabdaecgaaeggbeechfgfghbdcgchgfaghdhdffdfbbecfaeffdcdcdhebbdagdgfgfaedebeffhdfdadgcgbgffhgbhfegcdddhghadegchdfhgecffacchbdhgafadadchccchaegebgcfahcacfhdagbadbdeffdhafgabfecdhadgcdahcdabeaegeadbdcbabcbggebfeeeghegbagceghcchfedafdbhfhgbadfehddebeehhaggdafaeaacebbbahcadhecchgeecdddbbgcggghhadacebbgbefghhffdbahedafbcehbdgbghdcafabbfhaefgagghdbhaccebdhaefhahhfhageahbffbddagehhgbdhedhbagbafghgeegdfdaggdgfhfefhhfdceeddfdadcgageddhebghhdhfheegbhbgeebbhbfbafaeadeefceefdbehfcbfdhbhacgbhabeagfdcbaeffbagfaehbbdaccaebbebdabbfedhfhecafaffeegfhghcgedhaecafdgbgfgfbafgbcdfhbdghcafgdfghhhedfgbcehdfecghfdghgegbfehabgaafedccfeheheabchhffgecefhaehbchchefbgcffgfbhgdgfbedfgacfagecbeeaabcgehecefbdbaaceehcebhehdgahcbhedgaccchhecaeccagbcccbhcefceaddegbebdgadccdgeggdhafcbeegcgcccfgahcbcabfddbbahadgaaacfeahdcbfhhfgbhbbageehgegghfghfaecadfceccdhaegbghacdhahgggdffafccgfhacbcfbdcheagecbedacbgfgefegacdhcfbfdcafbefabhbfccheaecebgcbagbddcageadfeaffahccbbgbfbghhaaagbdcddahdefhecfebhhcbfeggcfgcggbhbddedchhhgecdaddhgefccdeabgghhfacaegddfccbefcaabgegahcehdcfdccdedacgdaafbfddfdfdaddhfhgbbdedfhaahcgdchaeedhbheehahgfgeghhcdecdfbfdeacfegadhhadgacefaaeahgdeagbcdegdhdhfedfddacddgadhedgdgcdedfaaedhhdedgbhbcbefheagbefechhhdfhdbccafgedadeceahdfhcgdhcggbfbgeehggaefehfhehdeggbfahbhbhgdehbaebgcbchfceegdhcbfehgdaffhdaddbdhcbbdebagfeebdgcbcbhgbedaadddegchadceedcchgddefehhdfahabhdechdegdabheebgdhbgdhccgfhgfhhecehchdacdbbafcgbbahehchfhgdegdbahacgddahebhcdfdefcaeehbegfaeabehbhffcfeggdabadfggfccfegdbhhbadaccfhecddagdbghgefdhhadgdefcffgfhacgfebaehdfgcdchgbhhefcacffhdchdefaahaegebegehgdafcfcefebddefcacaachbhffacdfbbabgcgageeahaeecegcfbbgahdabgfcafdghchggdgfdcbghaaebccbbfbcdhedehcebbcheaeacggbggfhahabebdaahdfhfbagdaddedfcbhahehaehbabfabeegdbheacedfagddhcdggdgccaddfdfbhdfbdbbffedfcgabaehghgbbgefdhcehfbaacbghfbfhhfahbhfafgcdchgcbdbgebhhcfghgdgfbgecfbddafgcefefafdegcdahchfffcgdgbbaeeabccfhhchefedahdhbdfhahfeggfgcbgddaadhcceaghagchhfeggeeccchafagadgbggdbcdhbdfddfbhdhdhbfcafhadhdcacaedchcddaggfhfagbahgchebhhadbbfbfadecghcffhedadeaccccgdbgdehebbbbegedfgadgegghcgceaeddfbgcaddbefgcbbahbdffbdfdbhhbdceaddceggfcddfeefdfabdbeaeghdhcgecbhfffddhggecdbfabgdcddgbccaeaehbdehahcafaehdgeehdhcgdahfchccebehfdaefabfeabcefcheefheefhehbaafhfahbfhcdeceggbagfedfbacaebbebhdghdhfcbagdefbffhccdhddbdhcedddgbdbaaebaceehgbffdhadcdefchbfcfeeafeabgaecedafagahgdbcagehacbfgffdcffafbcbedgfbgehcgbcegbeacbgagbcdgcahebehhbagfaadbcahdehfgffehhafbafgcbfbcghhghdhbdhehgcfehcdhcaacfgegegacfaafdhgggdfffdbefedheebccgagebabbageafcgahdfcebhafgfbahdghccacdbdcfdhhbhhfebbfbcchhdhghffbhgddhgffbeedddahfbegdhfccfabcgccegfdecaggfbbabafcedgdbaggbhahccdahgebhchedaeeachfffagfgeggffahaahheaghaccaghbagggdgeafbhdgedffdeehfcgfebfcagdgebbdfbagadefgccbggadahaeaggaebgbcheaaegbhdgffagdgghgfhcffafccddechedddecgchdcfgadfgbfagcaeechhhcgdfbgbdedchfhgfdddeadcddghgghfafafhhgcdbfdgebdhegdfbgaeehccghceahdhffcgcfehghgdfcagaadehfhgfbcfbfegcgffebecbcfgeffefabffadcbfhccdbecgbghfaaaghedebbecgbcbedgdgahhebfghedhfdfeababcedaffbbahfghefdfcbehfdeabaacabeeeebbfdceaadeggbaafhfadfbdgddhhhedbfaeheeahaggbggggdgbaafgdagdacgbhhfhdbhdbfbcdhabcgdcgabcahfabdbacghghgbadcchbcadbdfhdgbefgegcgheegcefdeafhhgbabcdhchfdddchbefaachdgegceebecdeefhdhgadbdfbfbgfbaeegadbfhcbbfffdeacdbfeecfbdehfedbdeeebdgcfehchddbgehdabacfebcbedeaaabdgdaccdbggdecchcdaeaefcfcgbcgbebahcccfeadhefbeheeefabhgdfhgdbcfbbhddehdhgaehedeahbabageggcbhegagfdbbdfabfebbafbhgbagafeghgfeefccadddaeffaggadhabbahbfehfcebgbdabgefhaceaadbdcbedbdehhdebhfaaaacgehfebcfbfgehhadadhhdddecaedaffhbeegfgdgdbcdacgaffaaadfdebgegddahagegbcccefcgdcdacebgbecccgbfcbechaaacccgheecghdbdeheabhchahbbddadeafgcdgghaegdfcheghffbffaggdcggggdeagcgfddegaggfefcchhhhggdaebgdfcddfcbaffgfdechcfbbebachdcdfagcdcfaegabdgggdbgfghgcagfhchdhabbddgdhfdaabhheafbgehafgfeafhhfbaaegdedgeehddedafbefcbdhgdefcbgcbdaehecdachdgcddehagbdfhgceaddcfgdbfheahghcecfhgeaefdbecdbchefecafhhbhghhadbfdhbddhgedaaedhaadcaabhcbfbaffbcaadddcbhgchcfgdfbffcheeabfagcbacbdfeghdebdggbbddhafgebgfggdbhddagbeeahabchheachhcefgfdddbgeabaahbeebeecgdbcedbdffbdcegggecgfcheddaehfggahaeccahhbccfaadeccbfbgaegfeddcedcafeafebhghagceaegffegccdgggacbcchhdededbddhgahcgfacdcegaceaegchfbcbegefcaeaaecgbcaeeecehgedehcbaecfdhcfhhfhdhfecfagbcdaahefggghdbegagdhfagahdebaeabgdchcgebecahdefdcacaaaaadfbdbbfaehhhfdabfabbegeghhghhhhdebgfcdfhceghhgbfgcgcacahbhhbggechchcgfbabhabfbgddefdgfdaecbcafeahecfbdgccgdhhbccfhfeeaebcfddcadbefhfafhcddbcedeccbggcchehdhbdcchhbehgdbbgcddfhfhbdgdffheahfdbhcbbgahccbaeedceabfdhaafhefgbbabdbccbbedceahacdadaedaeahbfgcggdchfeahaebeeaegdfbdbedfedgcbbahecgcggbgccdgdhegegcfcfdhabbbcbahegbcfcbheeghdcgaaafdfacgcdheeadageddgeddabcddadeabhgbbededaaddbcaefgaababedfehbfaadbbhffcffgagaacfhcgachegebffgffbggaddcababhabcgaeebhdffagcfehdffbfbfabgacfbehheedfdgdagbcegbhdgabhfbbdbdbchabeeebhdehbgbfecehbfaacbbgdfhfehhaedcdggdaeefahcaahaabcchfhgcdgbecfgfdeadbfbbedbeccedegdbfbdbhffbcdhfhhbaeccafdehfbcbhfcfhgggddafghcfgdgdfadcdabbbecabffaddhgghdegfcebahgadbddceegheaecahfhfegaaefcbgcafcdgggacchbhhfbheghbcfbdchfdfadcchaafbdaaehhcagggfabdbefabagbdaecbeachacehbghheffegagcfgefefafbdggdafdcbcdhbceghafhghefdbbbcgcfeaaegdghfbhgededdbdcbhhebafdhaadaaagdggaafgeachdecffcebdfhgehghhghgbgebgbhcbbbefeccggebddhhcfhbdgheedfceeeffgcdcefacbbgeafgfeaadhehdbchfgfcehfgddgfehdbhbhefheahaacbcbgagbffgdabcggbbhbcgfagcafcahecacdhdaecdfdfdbheaahhfhfhhccabgcbafaeffgbcbgfdfbdfacdhhchbehccbedhehebffdgeabbcfhchcchebabaddbhgadfffccabgbcadhhfhbhgfaggabccaaceghbacbbaceafdhdcacagdhedagfbhaffhgfbhhccdchgccbcfbaaafdbdbccbhhaffceeeghggfaagdfadfaabbecdgdcgdhdfehbcgaadabcdgchechfedhhcccafbddfceaaeadfbfaahhechbgcafechehbhcgbhgbdhfaacbacaeehfccfhghhdhacbgeaffeeceefffhgbdfhfheegedbdddechfhfbdhfhededbgggfdgbaefdfahafbacafddeacbdheefddcgbdgfbccbbcgccachdfeehfhgbedehfdabbfcdhdebcgecadgfhcfebdgfhceefefhbhcadhcffghgbfdbhafbedgdgdhdhfcbefbhedebbehdbdebdbchfacddcgdhbedgfdcbhdcddffgbgbdabaaddefbhecdaaadcbcgegbbdhdbagbbgbfbfccehfhhfacabegfchhfgcggahagbfhghbdggcfecheeecbgbaehccfccfadchbcbeahhgdbfhfbbhachebcgheaefdhefbfbbfahacfahgbggegcfabeebbbfagcbddcaecbghbffceegcgechagbbagbgacbdfchhdfgeddghhfbgbdfbbgdbeehehbaedhdgfbcaeahefacgdhaegdgchfhgghcbgfhdgbddcchhcbgfagcgbabafahehbffhfbfgeaahhabaghbebhfbafgaechgafffgcdcdebceddccegdddeeaceffedfbachcfbfbdafgdhahfdcahgbbdgghbdabfhddabedbcbebbdhefhdeafhgdghhgaefehffebggcchefgacgeggbffededbfagbhegdfebhgbddheffaeebbbfffbgcbfdabbegfffdgbggfedfahgbadggefafcegdfcbdhggghfeebhbbhhchdbfhggfacddhfececbccggghgaafhcecdccbahbccebhaeddfgfdedccdchdeefaghbggdaahbhafddcbaffdhahbhcgdhgbhhhfchgcbfcgafbbfghaghhhgbfcbddaddffcdhdbbcbgdddbcehbdhhfebgafgdadachagababadedeghehddhahaghfecfhdagdggegaebeafdhbccebcecadhegfebfcedbabbfcffhaebdhfebbgcfggddceafadgaehfgecffhgageehfdbcbafecbehbhfcdehbbcggbfghbcggfabgagccagcbfhdaedbffadgfbfgddebdfhdecgeaafghbgdeaabadhfeedahhbdfagbcefdecbedhhhhaahdheadhadhbgebefebchfeabahbhhbagehdedcegbfefhacdbechbcabbbaacahhacddeabgffdefghhcbgddgefaffcfebfgfadfbbcgehecgdfabadhfahcgchcdfbafefhfafbhbefebffbbfgbeahgaccfdcchabeahfhabefcccedhceedecdgeabhcaheehdbgddcafedbhceeghabcgfcheehdadcdeahhdhfhcghfcddbdedbcfagchccceggffgaedhhbgeebhfeebfggfeaegdgdbfagdacghbhgfdhfbebcbhahdbdcecffhfdcffaehhcedcbegcghbggfhchdeeadbdfgbfcaefehhgdfabecadhhfgdbcdedhbbagdacaechcfedhbfheegbcbcefghehaefdeheabddhaggbdffhdgbfafcgegfecchgbdgdhbchhaacffbadcfdhhbdfghhahfbceebfgafgahdfbeadbddbeggcggcfdehhabfhbcfcbbhcfaggdbhahgcfefchbchbdeaeggghhgcegacbbcbaaegebadcccdfgececaebggfeghghbhhbdffegbgadcgcgagaacbhagdgfbfhbfaecgbahhbcbhehhdhhfagggceedcdehdbbbccabdddchcbccaachgbbcfeeabddcffehffcaaeadfcffcheaafdfchfddbfagbhdgbehfeccghhbgebhbeedecghddhbegedhaceeegddfebbfadcfgghffcaedfchabacfegdhbadccbdfdadbhagbbcegedgfdacagfhhfdbheeeheaadagebaaheefbhfdhdahcfcefgabffbfacdfddfdhbaabgdabdheabafhahefabgcedghabgcbgdhbdbedffefcefbadccbegecgedegfdbeeffbacgehaafcbaedbabfdhbgeadhbadgfegacdhddefeebhfbbceaedeegdfgheedcegfdbbagfehfcagefgaadeggcffgbbafhgaahageffbhfhdcgecbabhcgfahgbefhefgfdccaebfdeabaccbdcdbheaffecebhcgceacabhefhfgcahfcchbghgdeahfhbdbgddgeccbcaheagbcbadhabdebcbaeebcheadgdeadeedcgfdgadgbgccadcehdgghhbfcggfccaeafahfdfgbaabdcgdfebeddbfbhcdcchchhbechcdhcfcedfbhhfdchadgdgaffdffebhdedcgafddcecbcfdbgghbeagcddhhfgdbbfhbccefhhgbecccabdfbchefgecehdgedhhfeeedcfhehcfbfcchbhfhdhdcdbggbfdfbaaefhafbfghhagahdhcddegedefahcchcgfcgcdeacdabeaedchghfdcbacbdeafcfhbhdfhfaageadaccgbabdbcgcfcdcfacgafdhcdhbaheacggdgahacfchhfbegdcgaffdbfebeabgghcfhbfbghaffccdfebgcgbddfeaffgdeaaebffhfgfcahffdgdfeeaabeagbgcghccaahafffhfeedhcgfgdfgecgddffbehdehdeeabdgfhbfbhcachghbfcfchgggccgfhcfagdgfedhefhgeffgchdegbcfdfdaefgedbcbgfacchahegfhfadebgbfdefhbddffggddgfgfffbdcabcefdcgafcgedbhagfgbbeghbeedhgdaahfdbdegfccbdcbchadaechggdbfbegbedffhbeedgfgahaaheadgabedcbfhhgdddaceeghdegddgdccefaehehbgeafddagecdabcdfahahccbghccggcaegacbecaafdagfedgddfffgeeagdhaddhdfahaahfdadbeghhbeegcacdhfchafgedhddhdadddehbdgchcabdcecagbaeaehhacgdcbgfffgadahfabacfcceedaehhdhbbcddaaafgbagaggbgahbddfgdbfcefdfhgaagbfecgcceaecadddgabbbhdfegddeddcebgghabdaffaabegbfhdecaaadeehhgdaechedceaaeabagcgffchgdhbhdagbehfggbbbfbbbbccheaeccdafcbefcdggcdeaefbbgccheegbecdhfdehebegecegfagbfacdcechbaafcdehgbgcccbgefebgccdcehfbbecceheheeffchhfafbgbdedfhgcgddahfcdegcachffgechbdfcgbgeaeghhbhggbbchddccahafbhgeebdfhhgdffcgeaefbgeebggcfghggfdcggaffgacdcahceedcahehfgeefdccgebeegbchdfbdeehahbbhfaedeaahcdfhebdccgbfddaahhagbbfgbccgccfffdebehehffebafbhebgfddeefgcaaafgdbhhadggbdhbaabebhcecgbaedaedfcggcggfeeghdahdbefagbceccagcebhhafbgegcafcefbhgfegdgahadhgfeafdaceggcahhcdeeccbhaffbefeeebaegdebhchbcgbfbfbeacdahabeffabhaffdbgcdgdgeedgceccgfcgfeccbceacbgfdehgccehhhfbdhdcefabbcddehdgbbdegccaehhdgeecdhehfeaggebcdfaegdaefdfbcefabbcebgegceeaagcedcabfbgcedeghbgacbfdhbbcfgcgefchhcafdghhbdfbeebhfgcehegfcbdggfffhfcdeccffagceabbgdfghedbfghddeaccdfgfadcaceecffabcgagbcdhbgcghfaccghcbbcdggfddgegefeghafagagffghhegcgaebgdhbgfgebdbhcbfchfbfchebeddcdadbdccbhagbdhafafahcbeeabgeebghbcaeecgedefgdfeddecffhcfaacebaddcdhhffdabahefdhahcgebabbadfbeaegdefababdaahgdhgcbegcehdedaghacfdgddadedeecchbabcfhebhhgchebhggcfbgffcabhcdgedagahdcgcaacebbcaehbcegeehdhccdgcbgbeaahaabecchcggdadcfhbagecbcedaghbggbghgacfcadgbgaggbgefbghfbadabbhcagaaafdbbbchbafcgcahahfbhabacadchdchbfacgcbhchcbbcabbfcbgdbaeecdaecbcddafeaadcbeebffhhgfdafhehcedeffhagffgfaagfehcbgcadfaaeehgbdcgachgheeeeecbabecagcddcehgdfhghghbffabcefgghhadbabddefhdddadbhbabggbhagegedfeggehbadghgccgfeggehecadcghbddghbfebgeefddhgbechcgggbhbdfaeaddafaeggacddfcbhgdgacfgdehgbadcdgcagggegbabgcdfbgebabadfhcghfaddcdbacfgdfabadhbbdccecfbchhbeaehcaadcgbfdbgdefegahaebffdfffbfbbhbbcdheadfhgcedafcabdfhhceeebffahgdcghdbechggcgdegfaeehgadcbahbhgecedffahegfhfbddgdhccgcfadgaefgbhceehedddbcacgdabdcebebbhhbdfheebbbafeeafgaheehghbcafdbeddaaceeeffedcadhhehdagbhadhfhaccdccgggceeghghcfggebgddfdgeaffchaebgdaahehgcgaheheffhadchhceefefbfdefedbdbdbcdfbhcggdbacbcgfhccbagffcbhfccgefdfefecafccgfbeedgfdedbgeadgcbdaeaecehccbfaggedbdafhdgghgbgadbahbfbgeeafbaehfhaahfhddfcbhaccbcbdhdbdhbbabfhgehgdfggadbccbeedggggbhbaacabhhadgghdefeaggcachdafbggaagacgbcfbfdaehecdeabhadgdddecbecheefggchefhaeechadahddfhhadbbadaehfcghccfbcbffbgabfdfdcedgffgafchdffchhhacbghcehdbcaefeadbfbbcdbfagahghaaaghccggdagafdaaefbghfhfffffdefdfdchfafabeaghahdfabffacdghabdffaahafaffbbghaggeehfbegdhechffecgecgbcdhdffcfdbbhahaefdebfdgdabbedhgfcfahccffdgfdffacbedghcbhdcegbcdehddbfagbhdeebehcacaaechhedfgfacedffbgecfhgbadacddddhfdhbgehefbaahgbfcdcbcdcfeeahhegehfgfcfbhhchgabdcefdgafdecedbacghheebbgaaaagabbcfgfehdhdfdhgdbecaahccfccfcbfdchbbefahedeacdddhgeafgccaehdfegadhbhebhbedbhgecgcggheabfeaacegchgdhcegdabehabcgdaedfeecafccbaebghabdgeehbdhcfffgbadfffgchadhfegeehacdecehbgfhedaeggbdedcehbbdhgaggcccegbgfgfbbffhdhchceebgfffdfebhgdeefcbdhcfeaeahhhbdddbbahefdgebbafgchcbbhgbdgacfcgbfhcfggcbegcghaebhgdafbcbhcdeebfbbhghgabchdagdfhcdcdbdfcchfhehefaeehceaedefbhcbcfdfghcabbgafffdfbheddfhhbeaagbcefhcebdfdbgagdddechhgegffdfgbhafeaaabdfeedfcgafcdebbbaggddeecfcgfcggfedbhadgaaadecefccefgabafdhcffbcbedbegheghadbeadheaffcfcfefdcgfdcbeghdcgdcbehbaggaddcafafcdhaaccbhabcdhffacebcchcfcfgafdcacdaefcdgdgbcdgcfddhfdcdfhbfeeaegdecagggbehdhgffbbegegbbfchbghfecchcafbcbafagdfhecgaahbgcahahffbheehbfbcfhcecadgcbgcbhadaadhfabeefdfcfhhecdgcheeacgbbhebhabeacafhdcbacaeeecgdgcdaafchbdgbeccgchfgbggdhdhdffgehbeagghacgbgadfdccbebhhachdaebeecaebhdbbbchcgefahgeafeaaddaheedgehhddaeedegbadbhbghhchhfchegdafhhedcfhhadfbebcdcadbccahfhedceacdffgcefcacdedfhggchafaachefcageddbbffghfbcbehbcfdcgacgcbcadcghfbahggffdghfdggfebhccbaedcegecgbdgabeggaeffhedfaeecggcdbehhacfbfechaafaedfehabhffbdddgehgehabaffcegccghfedeeedbbeffhdbgbffbhfheadccfbbcfegbabdcfahedacfghgfffbfbehgfbbcfhdgbgagghdchfhfffccdeheagcfhdhfdcdebdchcfbbdahagbcbfbffhhchdbegehcfceeecgffgefeghfdacbhcdgffcdbbfgdbchdafahbfdhebdedeefhccefffgcdcegbhggafafbhcccgfgcdgffccdaafdcbbebacbfcggcaaehgdbbbggdabdbhhdaahbaccgebegbfdadgcehaccbegcdffdfffghhedaaccffcadeecfhegdcaghfbfcgdbghfghhafedfhhcbebfceacchadeccheagbggahdecadbcegdbahbdbbdfffhfbhdcfbceeggfbahfgdhgcabebebhcaedhhgebabfhhcahcgfffehffdhcegeechdbfacgbafacfaedfbabbghefbbdfffebgcbbacbfcdccagabgbceahbbaegfbdgafhbfbccefegfcghbabfaahcadagfdefaegffahbfeadggchgdfheebehbcefhbfdhdahccfgcafacehfbgbfhgfaabfhddccgdcafhhhhehbaggceahdgeeggbgbeadcdfdaechdghegfdacdafbebhcdfdhghcbefcbhbefabdgeeahefaahhdcfgbdfdecagdhaheaaageegdaedadddfacgdhchbcgecgeggegfbcdechadcdghdaggaafbcdgebcdagbfheaegaebchaccaaaaafccbahccccadhahaegaahchhebaebaegchhcgceaefdefdebbebagaadbahcaeaddafbccbghecehgfacgbbgbehbdbbhbecbcddeecdbehadebfccgadchegaffbcadedgaaadbfcbagcfaeeahghdehbcadcdhfchfccgheahccfchbcghbceadgagaeffgedagbacbheeegdfabfbdbbghbehfbedfhedbefcdbgahbfhdcagdbfcdbbadgeafaegebbhdhhcbfcehccdehfhbhhefdecdabhcchfbghcdbgdebgaadhbcgfhcccfcdfefebgcbbgchbgahgbcfcfeaegcgdebabgecfhdgfgfgegfdhhabeebbcdhgabgbhddechchfafbgcefbfggbahedgcdhaehdadfhgeegbfedcbfhhdahcedaggahdhcdcacaegggdcbfdgedbfcdbfeaeehhdbcfbeggceefhfdcehffeabgffgbbfaegcbaghgaecgdhbfdadbfdcdahbcagceeffedfcebeceedbhdeaahcdabecbcefhbddfagbbcdfggggbdgccbfccceeebbdcehhefafhdcgbbedecfgdcbgefcbgdebadaeabcaeeggfcbbegaaabgfgagfdcgdggaghcgegecegdfdbfdbgbgfbecehaafgadgcccageefhcaahdbgeadfefbdfbadbebdgdeehabgcbgceaaaadfeahafaaacecfcfbhfcadeccggcghcbegbdggehhgdbdggffdhfhdhbcgdaffcbddfccbbbhecccahhegfdceeechehegbhcgbehcfghhabhabdgggaccefbbefhffbdgfcbcaabbbbbcehadadfeahfeefcbgfaeabgababcbcffcfacaggafefbbhdheddeecffcghdbeadcbfchddehafahaadddahffehdeceadhceefdaahhaeahfacadcabheadadhbghdcdafdaedaadhfdcggeghecahddgebfhdbaaeaehbecacfcaehgddadcdgahhghchhcdhgdadfbfddfhcdcfdghheagegfgfebaehdecbfhebeddhfbddacaaaeggcdcdegdhdfaafebbhfbfgeaggahgefehbhcfffeadfbabcbbhcgfggeehdddahcbgfgecdefaffbahchbafahbegehbehegfbebdhgbhdgbdfddheahdbdbfdcbcghhhebddhedccegahbhdbggcbhhecagaagaehdhghcabggbghabagacahbebcdccbcgaffgeagfgfheehgfgghgfbchdfbfgddgaaeeadbhaadeabbghbefcgefefccafbaffegaffagafgcgebhagbgcgchafhfghdddbebgehgbfaabchbabhdhccahcffbaafbeghbfgccgcdacebddecfgceaabcachcgfbhchcegehggdhbgdeecgacgcehedbcaccccegaafghagahbeddddgbfcabgbegegbgchgcfebfcceeghhbdfdaadcgfgebefhgffacbcheeeacdhegfhhfcbdhhhadfhbcebegddchhccdbgbgfadhbghaghddhefdgbbbedbefdhhbafgbbfchedfegaddfgbgacdddhbggahgffhgdcghfdddeggbfhafcdafcbeabdghbgfeaddfhhadfhecgehahagbbcbdfacgghcgdgdcfdfccbfbgebfehhgbabhadfgcaefghhddeffgcgehabdhabbbcabffaafefdefghbeehgddfdfbcfcdgfdacbacgeacafahgeegdhbacgbeeeacbdcdecgdhgfhdfhbcdhfcbfehhaddageeahadfdcdabggaaadhffacbabcdecbagcahffchbdahbbhbehgchadhcfdgaehgghfdeacfddfeeefaddcddgcfdfedcdcacheghgecbbgffdgbgaecgghcedfgghgahchgbdbcehabdgcbggdffdhbgehfeffdaebbhcddcdffbhgagcfdfeedadaeaghacbbcdfffaccccbcadhdadhddceacchdeaegebebcgeeafgaafdaacddehdhbdcgdgehaabchfghceacbdcbgfecfabgddegcbgcbheaecaggaahdcabheeeefdhbhgdaefcdbchdcfbcfaghahgeddbbgacfgfgccafdcegfbhhghffhfedahebffdcdaagcadfdadabchabffacbecaaeffhabaahcbcaecdeegdehabacdefdebbcabdabcdcedghgcdeghegaebdaghehaghbbacddfagdhegcbebfcbbdfbbefaeeaffahbdebbaafgcgcddeeeabfbfdcbhcgecgffcggcgdaaccdfhachbhahccabehggfddhcbcafcbhfeeeegdggdfagfcceabbdebfgdgdfhccdggafbgdfdddaffffggbdhgbceeadgchebhbcfehaacafafdgeebdccghggceabbbacefhdfhggegdhehdgdgabfhhhdhbebbhfhgaefgcbegbbfehachbhgahcaagbbfgadgfafhcbfdcdhbdcbfbhfabfaagcfecbdhbahdbegehgfdagabgfchdchbefghgbghbfdccbgbheehcebacdaffhgceebcfhcgffbhghagdffgbggdbgahghbcdcfbbhhgeafcagaddgbeeaaggafehghdaeebddahefbedchgabdebdchdhedfdgfhchcfhbbecfaefgegbbhedgadcdafbgedfgaehcachagehdcaebfhafccadabbeegdeccgcegddccgfccghbgeebehbfafbgagadechcfcfhacccabehgaachbahgbfhhfcehbgfedeefghgadfgdfacgabecgdbdffchehdhehfcgdcbaaefbgdbhhdfdfaacdhgccggcdbagdcgegdffggefccahcbbfaaadggfbhfhdhfhgaedgchdebedeffbffbadafehddccabaafdgadbeefaacfcacdafdgbdbefdeheeehcecdbhbbhdgbdafefacgddcbggaccecebehcdaddebehbbdgcfefagghegbgddceabgdcbggcdfdebbggfehdcghbhfedhadaggchfabageehfdfchefbceccbgfagaaegddddedbaaafdghccedfaghbeebdechcfdgahbcabcfeafgdbcacahdedfhhhhbechebbgbcbhhbefefhehhddegadfhchdeghghghchgbacgfagbhffcbdcfbbhaeegecgcbababbchgcfacdfeeahbbabbffabhgdageahfdgefeehhbedbdfddgeadebccecaadhgggcdcgdbhheacbdfhagcehehehhechcafedhcgabfechgffffdaccebgdadfhffecbdehdgfaaegfbddedfhagfdgabgggcahgehbcebcahacddggafggdceddcbbfbbdgaeaegdefdgagfhgcfefhabcdceaefdcfhcbfffdaedgbcedaabhbcceegeadhcagfbecghdccbdfghfgaehcgdgehhhgbhfgabbhaebcffhdeecebbghfeeedddfdaddbecbaedgbdbfhdbafhacdeghhbecbhgceadeehcfcecbhdceccgggfffgbaaagceggbdfdahhdahgcdbechcheaffaffgacegdhdgacgdcfbfacbcbebfehceeacecgcfgfdghbbcgchhfabgedeacgegggdafffddbbcccebedabebaaeebgcffbeabbfheaafdchhddddfhffhbbaadgfecfgdcfhdfeghdfdgagdhdahfbhfffcbhhhcbebebfcbaaehaccagdhdegabecddbcgchhhafbbfbfecahcgcbbghbadddheffgeeffbhghaedcececefddfedahghddebabhfcgdbghfbdhffedahaecadaagdeadfhaafebddgehgcecffbfbdffdfdgcdchcchhgbdchhbfbfhgcadedbbggefaahacbhcaafcaedfgafedfahbbahheeaedahfhbfaghaccfaccffafebgeafbfffafefffcfdbfgdcggfddfaaggegefdbdehhbefebafggbafhfaccbcahhhdecfhgehaaeebebhdchabfaehbgabfhecbbbafaafeegbffeafebcefbgebhbaddcffccfcacggddehdbdfdhcefggeagadafachgehacgdgccbdfggebcchaghhgdhddcdbgcbbaehcgafdhdaagchgahfhcfcfhfhfaagaffddgahfehfcbeabdgafdddcachacgbhdedbecgabdccadddbebeheghgfaadbahfdabfhcgceachdgahhegdcgbagbdhbceedfbchheehhddfeceabhdhadfbgedbahefbgfacbabedgafcbgbefbhcdfggggfcegabhdchegcdhhfaghedadgdaebhdhbhfcaefcdbafehfchdbdgbgefhbggefhddbdhgfdafaeffgeahahbgdgfeedacddfegeddhdbahgfgcgfcfgbaegfbcfdfbabheedeheehcbfehchebaffgcgahbfabhagddcdhgcbhhfhbedceaadcgdcabcbachdfbgehafhhdgbhbdecdheccgcdbddddhbeffegddfgbgfccbefabhdhbgafceabfegcaefdcdeabhccdadehgebeeggaghfcgadcfgebdfcchefhhchfgaccgadeaaggabagafhdcbfbfcbfeaccaefgfacfaadbcdhcagfchceeefbbfedfaadfafcbffchbbbbhgegaacffegcabhaccgchadegfehgfafeedeegbbchdcbccdeafdbbahgegfbgcfdgchedbgdeaehchddehefhdedbbehdccbecfhddchdgggfcbcbfhaaddbehaabdbffhfachhgggedaffbcfbcaedfddffggcdfhdahdgfbcabhgcbddddhgacbfhaecdbbhbachfdbgeaegbhbecacdceaceeehgfghgahddabhbffceghhgbcbfcdbhhbfehecadgdehdffahbhgafacgffbheaabfhfhhbfdffgccgbdfaedagbfddehdeaaegadhfgecegedhaahedhcffgabfdggeceefdbeheafadeaeeehdheafeccaaaeceahhbdgfedghagdeddhchahecbeccaegadgbhehdafcadgegbdaadhefbahdadbahhcgebbegdebbaacdadhahebaeeahfbgfdebeffcbbdcbdfeeadehafhebadgbcdegeaebcfcfhdbeafedbedgdhhddfefbadfahhcebaefbafgfahbefedeagbedcfhafghadaahfbhchedgfhdcchcbageddddbccbfcbeacdcbafhfechhbbabaeedahecbfhegdeaggbgeaeacdhdfhffebaebfgccfgbacbgbdffdbfgefbbeggaahebecdghchhebgfedcheafafhcbfacfhggdbccaebaacgggbagfadffchhaabfhhedagfbcgbcbhahabffbbchdcgdchbbgfehdbafabhbaaaabgfchhbcbhgdghffebehdeedfdefdefecchbbaedacggbddffheadadadhfhdcdgechgddbdfhbgdfdaehaahdadcgcfafdfadddgegedhcgeggbfgbfbbadhcbahefhhacgeachaegecefadgfeafahhbhgfegfeadabfabbgfecdefbbcbgcbfdadafbfbcacdfcehabdcehagachgeadhbghgafhcfbfddbcdcfghegfeaeceffdgdcedhdfffcaadceghcfdachagbedghbbbffbbcggfggaacghedcefbeecahahbbbggchbafggegggffdahhgaeccebcecdfbchadhgbfchdaeadfhddhhfbdgdhbgecadcdcaehcecdacgfbbaaafbeeedfdahddbhgcdfehahacgfehgeadgehchefhdbdfabhdgddgddbbafagbachebceghdbaggahfegbheecffccfbegddcefgcfcefacgaacgbbcfdacfchggfbcaghgaeaecbhabhchadbfgbhdegccedeebeccadgcefcfeeeehfbfhabdhdfdgchagbcgeabagdfcabhhhafgbgbabgdhachgdbfacgaabgcbhbbgcgedefdfegeeaeddfadhgehhccbbdcafaeaecdbgbfcbbffhfagdegdgaeadgabgebcgfdegahacefbcfhfcfaafeabcacafdcdafahghhadebfbaddgdedaeecfgdccffcdfbbeabaecfgcabaefeecaghhbbbhgdcefdafeacggaagbbchfgbffaegbffhbhdgcedgefecffbhgdgdchahhffacdhdcdbfhfddcagafhhdcfgeegdddbdgecbgfddeahachgcefbhhgfecdhfhaafedgdabgfbffeedgaaahhgedbadghdheaccdcebhfhebdhaehadhgachafghbfdbhfebbfbhefaafaeeahdhhgghdegebbfahbcahdhdaadfahcbhfagdgghdedegbffchfbcffcfaafacghhgfdfdcaafeggbdbaaccfhfcafaahghgfebcadcabgghabaabddhcabcfbceabcfgehghbgaheahfaagddfgdhaaadeaegfcceacfgcfccehdegghdeccfcdagdefbhhfhbdgeaageabbgaabedebfhbecgbdfabececgedeadgbbgcccfgecffgadhdaaefcahaeceffcggaabdfhhafegfagaagffaffachehfhfdhgecdebdbgcggagggdegbbgdaccfbhbbffdbbfecdgabghhecdcdeagfdaceadffbbgcgdfbbfcaebehfhcbhbgcbbhbeehfffadafeccgchaggffagfbfhdggecddaabaebfadhhfgheeebfcgghgbfegahbaacaeefehedfdcbhgcebbdahegdcgdegdgghcddchhhcbacacgbdbbcghgafbededbdfeghefgghgahbhaeabhgbfhggdccgdfeaddebccaadhbchgcafbbcaaadcccfhgfcbbddedehcfbbddcaedcedcafecddaagbcbfgfbfhggbcbdcggfcchcheechedfgfhddeeadcgeehhhfgeaadchhhchdfebcdefhafdddhhchgafcafgcefbgefdbgfedcedhhgcggffefchfhfhecbchggaedehgadfhbaghfdecgdhfagbchebfcbcfgbdgebggbefghbafehdefehfaaccceaagdgceeafagdahdfecaaafhffahaceaccdaeaffffdbfcedghdhhageggdgahgcbbdgbadhfgadaeghdbgccegadcgdbegdfbbhbeggcgbcchbgbhadehdhbbccfafcbgbcchbefchacagdaggefbdgcfbhggbhfdchcdeafdahdgcdeahcbcadabcgaeffhhebcabadbhhhcceccgeegheaccagaffhbgccacfbbebdhfgbdcfbbcbdebbeggeafgcfahgbehfdedehfbbgdccaedeccachgeegecaacfdgahgfahdebfefbaadbcchhggdagdcdgbdfhafgdbhbffcgffhhhggfebfceafcbahaafgegffechchebhdhfaehfgdfeggefgfcebbcgfefhebadehaedhbcdhgbfcgehbaaccghhdgdeggafgebggdbfbccdagdbhddbccafadcgbceahfgfahcbbeebdhdcdgdfbecbheabhebgbhdbgfchbgaegdgbccgdgaeffegeahcbgfcecedddeabhgcbaaegabeffcbgcdhaacfcgagbegceeeffecdfdhcacegehgeaabcgcaaggccdhaadcdafddffhebgcfgchbabbahadcdccdfeggbbbggachgeffgeghfhhehcgceafceeaffbeebgdhdaebecabcagbceehfbbbfbhdcdhdbccedhghbgbdghfbdbaacbcacbdeechfebchaahcgaffhcgcdgdghfgbgbfcdehhfbhgbgaagfffadhdbcbahhbfaghdchdhacfcafcgdhddccgdfadehecacbdeagdbabdagfgbebegedbbdefcahccbggbebcfcffbcecgfhebcfcfbahbhcdaabcedebfchgedbdaahccfehgegaeadeafgfadgfffebafebfedhbhgheehafdefadcagbfdgbehgbadfdcgcafgffgcadhagcaedfhbhdafeabbddhgefebcddcgcceecahhhbgcbehcfafaadefafhdabbddfhffheeadgbhfdegbegebdegchhdacgfbdcahgacfcbcffagcgddbhbdhaghcefehhehgfbdhdfeagdcegfgfhbehaecebgeacdghebghhdafgcbeahbhbggbcafdgbdbecabdhaccahadbedafcbdacfbaahbeaggbhbahecadcdeggfdaghabebbfbcbbahchacheehagceeabaaahabdccadebefahebbdfgcfeecbedbedafedhgecdfgagfehhaefccbhecdhdaddfhhegdgbaebgcffbfcgaehhacchfccbhcadadbbdgccahhbfbhffgefagfgbhhabhebcfcfdehdehebadggccdcaaabahcbggdadfghcfcgehhfcfdehghhhhbhhdafbdgebeddbgbgfadhfgeeedddcecbhdhagffhbaccgdaddddabhegcabeeegehfefcbfdchfadgegbhhdgdbadceagcefhadbcaeehcecaabbhaefdffhachgedeedhffhcbgegbegcfgccdfhbehddghgcdcbbhadbghhhdfbaddchbcafbdbhchbgbchbcccbbbaegcecfhbgbbecefcgedeggdhafbbgcccaehcbgdaheebabdhfhddfhcfedhdfbfgfeagcegbacdbdgabfdecchahchcaahgfegdgccadedeabebhhfbcebbhadhacffgdbfgdfbhafhbbaaagcccddbegaebfchbdehgbafbffdgfdgdfbgbehfdabefddggafebfcdchgaebhahagaeffhfgddchbahhfaehdhgbhcdgccgacdghcdfgghfaaehfedeaccbceeahghhacfhebfchehhedgbacfaehbgeghdegcfaaeebbhaggaccgecabcfbddfbcagacdachfdbeehcebecfgdhaaaedffgfdghghcgefhabgcfhhaffdegdecgbhegddfbchhgfgggeaeehebfhfdcbfacefahafbcfaachgadgehgaadhfgbgdcahhahhgabdabfhhfdfccdcdgcaedhhfhheagdggebgfggedbcfdfagechafgadfhhffdddhebfchbgaddebdcffbfdhfgfefcbageacgfffgdgcgcdceahgfcfdachgfbgdfgfddcbcfheebhgfhfdeabhadhgaafdfdbbhdcbbbffcedhdadhaehbhghageddaeehagabhfgbbbbebedcacdhachghdchhgghfgaedggehhabddddggcgacfhfhgefeeccehfdfbcebdhfgcdeebfggedfdadhefcaehdbbgfcbehagcedebbcgfabfdabacbfcfgddefeafehhbcdcdgaagbfbcgbeaggffbabhebebadcchegffgdgeeacffcedhbfhceedafedhgcdehadchhghbeeeaadbfddbhgbecedbhgfghabghhfbdcfdcaehdhacgbgafbbeahdhhefhdcahefcgfhfbgfdegcfedgadfdcfhhedcecgbefgdchcadggfdcacdehggeggabaedgfhdedgdfggdedhhebcaaagfgefheccdhcgdfehccffhbegffafgaddhaagecbhcdgfacecfchedecabcfhcacbadaffbehecfefbgcdfggbagdcdceefgeagbfhgfdachfdfhhcffefehhhbedgcagabehhbcadbfggffacdeahdhgfdcdfccfdgedhgdchaaffggabcaaghgddagacagggcbfbehaeagcgechgchebfheggfagdgffhcgdchacfcabehhggehddebbbcaeafbahadbhddefdfbcehaaheedffehfaacbacbddahheecbgfgffgebchhadgfdgafgcgcfhbedfhfdedbbbfdefceaabehbbfdhhbgafcgehbacccdafhfhdfhfbggceccddaeaccfbdfdghhgegddcadhcbfefhgbchfdbhadcfgaffgbebfgcafebcahchaegfhhehcgfbhcgfdchaabaffcafbcebgcggccfeacfheefageahfbecdehegeffgddafaffdcfhgchfgaedbafefeadafahadhfeechhhgfbgchggchhhdeedheaadaddfhhhgghfeadgabfcaecdagghcghggdbdcacbhbgdcbbccgeccgfcedchbbfhegchgeafggaahccbagddfafbdhaebfdfdfecbehhcahbcbccaffffdgachedehbaefcgcbfebfgdgagggdddgcebbaefaffedhcfbabcfhgdaecghfbghfhagdggbdcedfbefcgccefcahaafbgehfffaddbgffbcgfhbebdahfbgfbdghafefceafggddafcffdbggcfddeaehgdhehegdeebdhfdehabccaaefdhbddbbgafffeabacehhhdgafacfagcdfegafhgffdcbdebfaaeadcaaccfcaaffedfbddgagbbbfchfcdffgfgahddhdaehebahehhcaaefcdcegabefhffdaegabgecgdhfcbfcfceafahfcdcbaheaedbfbfhhbgfdacgffcgcdfhfabgbbdbfgcchabgbadeagcfdfdfaaefbfdcggddegfdghchhfdhdgegdaddahabfdddchhgfecddeccbfbfdgdgghbggbadfdhhcgfhchcgdeafcccfafegefedhegeafdcdacgaeedbeadgcagaeeecbhbfgffdaahacfagbehfecehdchhhdbadcfbhdehddafaadbedhbfdaafhaecbefecgdfddagdfhdaaadhbbcbbaabecdbahdgcabfaaafhefhebhfcbgdbgfgaahahchbcahcahhhdehhfgehhcdbaahbagbhaaacbhebhdbchacfggefbhgbhfchdegdehffgbhfeaaeacbgafdbfcdehfedbcggbedafcfccfgchhaaeebbgegfccadehbgdfgahdccbaeahfaebcfhgdeaffecefahcghcbceccadcfdggfdfehceehagdggcaebcgdgaghdaehgdebaaacffbfdedcgegagedffbeabahhdebeebgbgahcecedgcdfhgceagebgebcacgedegcefebhaegchdbffffdchbgadgcbcfgahcfddfdhdggghedfbghahfaddcefacghfddaagadegbecebecaecfffahbfhedhbhcbhabdfaebcbcgdcdfhachheehaagbhacgaebfeggghafccaabacahgfggfeheeccfgecccbabbfdefdffggfedddaaceeegbcceeefffgcbcaeafcgchbgcbgefcbdedgaacffadhbghfgfaehhffbgdfdgggccecchhhhcgaagfgdfccehaffddabbhdddffceebhdbhbhgeeagbaggfcbgddfhgaeedbaeadgheffabghcgfbdhcbdfgcehgachagheehabebdcafafgefbfageccdacfaddhhaghbdaefacggacdbhdadfcgffdfahfhhdgaghfehhcfheabddbhadfgabdaaahheghcfegedacdeceagfhgaeebfabfabeeheheafaegchcfdcdabbaggbdgdbgefddbchchhgfcfahaccaedacbcfhfggbebefddhccfaecadccfcgbdacfgcceadabhgecfgedgbfgeabcchdfafcghechhdagbeagdfbbghachbebahhafbgegbefeeefbedebffhefcdggehgdhdfghdhdadaeabbdfcacceaehgcefahfdeddhcgafgefhfaeabhcfhgffabdbaaefdhefgecebheghagahagggdehehaehebceghccbgdacchdaacbgbhbfgfegbdddfhbebdfhhfcbefbehccacdfaabhcecfbbgfcbcbahdbeadaafdahggahhhbebgfcedefffgfbhbbcbbaechdahchgddhbbbfefcbdageahfcbhcfbcabbcaafehgfbdbggcbgbfgadbbcdhdfhehcehhaggfhbgghbhgcfecafecbdfgcbfefeegdcdcdcaddabfffhfddhegecbfafcebahdechgccbcdghafedbdhhhcaecghghhgddacbcecfhaehgbdhecgeehagfhfehdhcdbeffgcehhefaheebcagbbegabdhecchegfbehgdgcagbedchdaaefhfgcedegcaehcbhaefcfedbhfacgbhdaebcaeghhhdgbefbbddghghgdaabbhebdgdecbdbagabdfceafchdbfhbgacffdbdgffaahaghcbeeffchefbcecafffcagfhdchdbhcabdfgbcaagfbaceahbgbbegaaahdchfcabhgcbgcaeeagabfbhgcdeddechgbebcfaahchccdgcbgdghcebgaebehadafeccedcgceafcdgagehbaahafaeebhegdhaaccgeghbachaadhbdaadfbhbchfaceacgdbcbadcccccfceacedhfdahcfhecahadadeaggcbbegdahffcecfechbbedbdeedhbdfhfgabfdceahgebeaddcfhfgcbdfaeagdfeehbhbfaaeebaffdhcdeafgddghdedbbhacgbagbedceahhhbcdcabfdafgeahfhhafaaebeheahdhgfcbhcdefdbdhbdfacfgdfcebbabaeagbchaecebfgffhacachgfeacfbcgbgghhbghfbehgcedbefbgeheahgfaadbhcagdhgaachgedcfhhhgegcegacgafahhagchedhgcgcgahfhgddffadfcbghbfhcdbbhebfhhhfhhcgfgccdcfbehhdaeccaeehaffheeeddhbbfddafbbbaafafhdfdheeebdagadbheceagefhghhgehddcahbfdfggfegagffabfggcfebecfegbggaaddfcbdgadefafhfdfabbbfdhbbaaaaaddffeaeeeacefbcbgcchdhccbecbecbhfgfchbgdbahhbbahdcghbbbcfedbgeaedfgcgefafehgghgbbeacfcfcgadefeaabgcadhaadhgbgedhbdbgfgbdheaeaaechgccfccabachffggaheggfbfcbbccfebdgdaafabfcachgaagfgechbebchdhdecchccecebfeeedeebbcfecgadahghdcbfbdhffdgcachdhdeagbeahfdhebghdheecebhhhchcbcbegbchgcgdffhgdhbcdfehgehgggahbbdhcghaafdgddegcgbfdffcbeahcagdbcddaceahhgccdbebccehhgbdgafghbhbedbghbfgaabdbfedhacghdbfehedadeegfcfgheghfbacfdcggafbccfbgabcefabhgagcgghagbfcddaeabgdhhbhadefefecfceeadehebbafbefccabbcbbffgbccdaehefcaehbfhggdeafecggdheaffchbcdagadgecabbghecabhchffgbfdhhcacfaagdhcfhegfdcaddhfcecaghdfhffbdfbbbadghhffdhfgdeefaggggbdfhagcghdhagfhgcebcbhffdcgcaeacafbaddgcgfcedccfgdhadefghdahaabafcaafhddefahhcfggegbbdhahahhabhgdhgbgbedhecghhefecgfgffffeegfdebcccbegeddgbcgghcafhgcedaahggcchfebgahcdcafegddadahcddfdefbchdbehccabedefaaddeehedbhhgcdddfdgghgacgbgbfdcghfcdeggfgfeaahefccdcadegfcacgcafhcaebgbhefhefdchgfbgbffgafaghbdgddcebedfbdcggegebhdcfaaffbdecgcfbfccbfacacbhghdhggcdgcadddhfbcdchffacfcdhdcfcfebegecbfgeafcchfegcbgegbhfebchhhadfefgbddcbfeacahecfaagagdbacahcdfgbdaegcfdggfgfbaccbbchedhgehahegahgfgacbgahffafacgbeffafdeeddabehabfadhhegebgbbbacffhfccbgffghbghcdhfcgbacdheeaehfbgdebecgbbfcheececfcdffgebdefccgafcbbfadgfffcchgeeahcfgggbdddfcdcefdbfghceeegeccadbcahbhaecdbehdbegcbfcdbgahccbdfcfgcgfcchgdefgfbfhccbfdafccadfffddhbaceaahefgbgdaafcfacdcedfcacfecgeeceecababhdchaeeaghccchedbbhdadhcadeaeecdhechahhggbabafecgdfggfbgafhfcbabfdbfcadacdbcafehacfhhgfheeegffhcaahcbccdgefgbcfcedbdbgcfdhdaeddedcgefahdefbghhadcbgdhabcheddhghdafhfghacecadbagdbegbehdeeghdehgfegccfdfbffeggcbhghachegdcgghffebdgeabbbggfeehfeffeheaghdefcbcgcfegfghgegdbccgghddhhdfggbeacggeeddbbcafadgdgfbfaeeaabggcchebfbfaegbgghhcfcacdfdacdadbgg' | |
total = sum(map(count_palindromic_borders, gen_substrings(string))) | |
print(total % (10 ** 9 + 7)) | |
if __name__ == '__main__': | |
main() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment