9 "import os,sys,inspect\n",
10 "currentdir = os.path.dirname(os.path.abspath(inspect.getfile(inspect.currentframe())))\n",
11 "parentdir = os.path.dirname(currentdir)\n",
12 "sys.path.insert(0,parentdir) \n",
14 "import matplotlib.pyplot as plt\n",
15 "import pandas as pd\n",
16 "import collections\n",
18 "%matplotlib inline\n",
20 "from cipher.vigenere import *\n",
21 "from cipher.cadenus import *\n",
22 "from support.utilities import *\n",
23 "from support.text_prettify import *\n",
24 "from support.language_models import *\n",
25 "from support.plot_frequency_histogram import *\n",
27 "c8a = open('8a.ciphertext').read()\n",
28 "c8b = open('8b.ciphertext').read().strip()"
39 "<matplotlib.axes._subplots.AxesSubplot at 0x7f383433e908>"
44 "output_type": "execute_result"
48 "image/png": "iVBORw0KGgoAAAANSUhEUgAAAY0AAAD7CAYAAACWq8i5AAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDIuMS4yLCBodHRwOi8vbWF0cGxvdGxpYi5vcmcvNQv5yAAAGXNJREFUeJzt3X+0XWV95/H3p1B+TAsSNKYsgsZOM1rK+ANSSFdtR6WFgJ2GTpXBtpJxKJkW7KLj9Ec67ZQR6xTbaW0Z23RYkhrUqaLVIa1gmhW11iqYIBQEyuIWZUgWQiT8cLTV4nznj/OkHq7nnPvckHAuyfu11lln7+9+nv3sc+6593P2j3NuqgpJknp8y7Q3QJL09GFoSJK6GRqSpG6GhiSpm6EhSepmaEiSuhkakqRuhoYkqZuhIUnqdui0N2Bfe9aznlXLli2b9mZI0tPKTTfd9MWqWjxXuwMuNJYtW8b27dunvRmS9LSS5N6edh6ekiR1MzQkSd0MDUlSN0NDktTN0JAkdTM0JEndDA1JUjdDQ5LU7YD7cN+BbNm6D42sf/7yVz7FWyLpYOWehiSpm6EhSepmaEiSuhkakqRuhoYkqZuhIUnqZmhIkroZGpKkboaGJKmboSFJ6mZoSJK6GRqSpG5zhkaS5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+xjwP8359VtXI36s5nAusAv57VT2S5DgGe2uz1/0ogz2y1+zFGKP8MwaHrEdq58jOZfDG7H3AhTX3v2O4lcFzfRKDbX0kyaeq6u8n9NnGYG/zexl8keAfJfnxmnzo8BIGe8tfBN4O/GJV/WOSb2GwJ/hLI7r90Z6JqnpH+9lfPMfjGeuAPqcxLMm/YvCO5cNV9bURy587qf9cvxTtpNaecyUfmfQiS/KrDF6Uw7/8762q35xjjBcw2M0MsLWqxu5i76226/tjDF7MMDg0sYlBMF5ZVT851HbPH+ZDgeUM3jF+lb5DE/vVk/157sV47wJeANzONw5PVc06rzWrzx3AdwGfo/N5ayeKX9pm/6qqbp5ju+b9POzt63OhmvUG4hAGYXBZVb1tTPvfZPB4R57Dm2Osoxi8m/8F4Duq6vAJbVdU1fZZtddW1Tsn9Hkjg2/GGPVz++798Tfhm8Y5WEJjoWm//D/QZj8+1y//U6md1N1zbPWvZ7+wh9o9pX+YF7Ikd9WYk/ET+ox8/hbC87aQX5/zNet5fhx4oKoe38djvJ7B83UK8HngrxiE+kf25TgLgaEh7QNJ/hj47Y7DGDoAJfkFBkFx074OpIXG0JD2gSR3MrjUsvtQk/R0ZGhI+8BCPtQk7UuGhiSp2wH/NSKSpH3H0JAkdTM0JEndDA1JUrf/D01s6fDIlGlbAAAAAElFTkSuQmCC\n",
50 "<matplotlib.figure.Figure at 0x7f383433e048>"
54 "output_type": "display_data"
58 "freqs = pd.Series(english_counts)\n",
59 "freqs.plot(kind='bar')"
70 "<matplotlib.axes._subplots.AxesSubplot at 0x7f37f28e9f98>"
75 "output_type": "execute_result"
79 "image/png": "iVBORw0KGgoAAAANSUhEUgAAAXQAAAD7CAYAAAB68m/qAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDIuMS4yLCBodHRwOi8vbWF0cGxvdGxpYi5vcmcvNQv5yAAAE9dJREFUeJzt3XuwpHV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h8GjgJu4zu7XKoWHUdZ1Od24NnA5xlzvnUHDV/eDf5dVd04oq4lz4dJl8+1atHKfR96Qf07VfW+Ae1/j9777XvMaMS0DqC3FfxW4Purav8hbWeram7RuDdU1YeG9HknvSvm+/3dfnAamfC46ayFQF9run/MH+kGrxr1j7kndQf4du/L+/vFC92Cdns0NNeyJHfWgAOzQ/r0nX9rYb6t5eVzqRbN58eAh6rqsRWexpvoza8XAfcCf0dvhfvJlZzOWmCgq3lJPgj8/hgfzdWgJG+lF+LXr/TKYq0x0NW8JHfQO11t7N0n0t7IQFfz1vLuE2klGeiS1Ai/y0WSGmGgS1IjDHRJaoSBLkmN+P8dHyBG/KpydgAAAABJRU5ErkJggg==\n",
81 "<matplotlib.figure.Figure at 0x7f37f463ecc0>"
85 "output_type": "display_data"
89 "freqs_8a = pd.Series(collections.Counter([l.lower() for l in c8a if l in string.ascii_letters]))\n",
90 "freqs_8a.plot(kind='bar')"
101 "'nyvlggsyglchxfeuytqcesqxpziufiggrbjhpayncruyfpsxufiupskyrectmmcncruyregxigrlglbtiblmecebzsvrlpuxpbibjajrljreobajrlufigjehbezywtmgjyxfqxictsgrdgtbjafyoocwtmjblctwwucqmgofrlfmrfrlfwlbtijlwuypmchjqxicrfchumtsmzjbimyvhcuvyrugxjcwpdtpuisrlfdhbaencyqumufeogrhcrjmytqsmsxjmrcsxjrmttiswzvjrfpecjitnidgemdssaitasvjhuyofgxpsxgmvvqfvrxiyxxmymbxfjpufigbeufeuuiiyzfavbaofbxicmsamqfisqwpgrtribbmtskhcwuuimcxufinbitrvpwxsmnbljppytuixgpmlifbgpmtfpeugsodvpkxicsnyrjeswcvokioreoyvnchggkirishiuyrerlfdpjeluasorvpjwzqxfkwgpsnyhsmrfkiblaigpfuiociersflwvpiuusufmoewpliufeuuiemrprwflhdpmuggbjmodsskeugsoygsmwtrlfzecypnyreyftrvbgxblhuusufeuuivqiblsoavjrmdyplcchcrfpeugsonvprsdmpplxiyxdfeolimemwcrufimczfjsgasnkmukiorxicjeylbtitfsxlmobiwcppnmoexigwqjeogenqyscxiyxufizummjvfgrtreucxictpuisqyqnpzumufmoyjfuqplxiqfvrajrlmsglrlfwajjpomxhsitqxiyxxcoomabzsvrmuyreuixgpmnyugxpsxpdfvqmocwtdssjsoeiomyhfxpasncyqumufeqjeomjpsvpurumiynppgxjrmorlfkiblxjkixcrpuoomaufeurlfgvigkicwuqidsvjrcdmqnsrjaeugsoqescioavznxfbytgrhygbbioswdgticvtmafaeoqxbpxisrugrhrlsmyhfxichbrecywfdssmxicvjlxfpgfnxtuidyrdpedixigwnycccxicfscelrlsmyhfaffewcffcrmmslgrhdssgrufiggkirehymoqxufigbemcxtlsuqgscajryqypmrlfzitrlbpvz'"
104 "execution_count": 4,
106 "output_type": "execute_result"
110 "c8as = sanitise(c8a)\n",
116 "execution_count": 5,
122 "('bye', -1461.9840974270046)"
125 "execution_count": 5,
127 "output_type": "execute_result"
131 "key_a, score = vigenere_frequency_break(c8as)\n",
137 "execution_count": 6,
142 "output_type": "stream",
144 "mark i cracked what appears to be the final document about the trojan deployment and i think i have\n",
145 "an idea about how to deal with it and with the flag day associates the principal weakness of any\n",
146 "system like the one they have installed is the need to provide large quantities of power the fda\n",
147 "came up with an ingenious solution but it is very vulnerable special forces could take it out for us\n",
148 "but that would tell the fda that we have cracked their ciphers so instead i suggest we let them\n",
149 "destroy trojan for us we will need cooperation from the omani government an armed fighter jet and\n",
150 "the flight control systems from a drone meanwhile we need to ensure two things one that we do not\n",
151 "send critical information across the ba balm and abstrait and two that we use an on critical key\n",
152 "generation protocol on that channel given the level of commitment the fda have shown in developing\n",
153 "this plan i am sure that they will reinstate the powersupply within a few months but with luck they\n",
154 "will not guess that we know about it and we will put it out of business for long enough to come up\n",
155 "with a plan of our own to exploit it in the meantime we now know that their highest security\n",
156 "communications are encrypted using a caden us cipher so we can start hunting through the database\n",
157 "for other intercepts we can crack this maybe the breakthrough we have been looking for in the fight\n",
158 "against the fda lets not screw it up all the best harry\n"
163 "print(prettify(vigenere_decipher(c8as, key_a)))"
168 "execution_count": 7,
177 "execution_count": 7,
179 "output_type": "execute_result"
188 "execution_count": 8,
1197 "execution_count": 8,
1199 "output_type": "execute_result"
1203 "[c for c in chunks(c8b, 5)]"
1207 "cell_type": "code",
1208 "execution_count": 9,
2217 "execution_count": 9,
2219 "output_type": "execute_result"
2223 "[(int(c, 2)) for c in chunks(c8b, 5)]"
2227 "cell_type": "code",
2228 "execution_count": 10,
2237 "execution_count": 10,
2239 "output_type": "execute_result"
2243 "max([(int(c, 2)) for c in chunks(c8b, 5)])"
2247 "cell_type": "code",
2248 "execution_count": 11,
2257 "execution_count": 11,
2259 "output_type": "execute_result"
2263 "max([chr(int(c, 2) + ord('a')) for c in chunks(c8b, 5)])"
2267 "cell_type": "code",
2268 "execution_count": 12,
2277 "execution_count": 12,
2279 "output_type": "execute_result"
2283 "max([unpos(int(c, 2)) for c in chunks(c8b, 5)])"
2287 "cell_type": "code",
2288 "execution_count": 13,
2292 "def cadenus_letter(n, doubled='v'):\n",
2293 " letter = chr(n + ord('a'))\n",
2294 " if letter > doubled:\n",
2295 " letter = chr(n + ord('a') + 1)\n",
2300 "cell_type": "code",
2301 "execution_count": 14,
2305 "def cadenus_letter(n, doubled='v'):\n",
2306 " letter = unpos(n)\n",
2307 " if letter > doubled:\n",
2308 " letter = unpos(n + 1)\n",
2313 "cell_type": "code",
2314 "execution_count": 15,
2320 "('afcaeuottacthrioletcserthshtrahkzorpfrgeoadppjnglternefeofiortsddoeeumscruernfetlaafstxientrvoonerhuahravereetsvsielhlostdoalozaesmnndignnrhohhtsnaoilncnssicreanneeiiierxtanesrvogieizxssdgpvoiaisaoaeoaedrnitrnyeigrpsshadhdtoipaateyennesagrobtlesrnroirzpbgedcllixalaleenigrrnxzrlimlpstoleftrdmuarieeeiiaolnexsaohrtlstobetnslvfivdovtpoaeeisciohipseveedtexfarnhebleaotohtttepnckaonhxetmvzprreonnasgdedoeeeoaamtcicttifnadresrtserosetrhcictpsaaehldhsfysoaotctbbsoeirnsadlztrrunrceptthreuhnktaceceelrxnireeeaeseeeidisogceomnrtejhagabsenitlxtrnbmielsaretesrngsnhebiosdienafleisahocifevmfatanatrniagnhatnmibniufenrtottrnzpaidziegdnmerhhiotretcesseildrbceprigaesoadltahievebrcenlevasadnnthneiteiisahuhhuamonefzhlonxhaeeeeosneezaneisetogziterlihtcmioirarfdoetnihtnehiikamrdmnadanaodseseizclsiantaoltcizmidentthltndytttmasbleaeetlisirtxturpfailteaoefeisiiizisikvtxisprbsinelphrmohiagnlslvitodaisdpnzddcaaotahcehtueirredaectosnrhvnaodoikoetcineneurrisdcouraglvimmuppditeanditmaaiaieleonnreedaodboiumelrotntttgitnrlrienniklzsogstcifzpipvidvssmnceiasiitsnneatitomrhbnhnidprlrepoznalsnvsdosanesitfaenltgodatteeaisicrootmsmfhauenirsghznxeintegodiileedtarnosrcaaendtcuttfdrbehtmfitoordruiaozaanoeeldoinhusgiteaoriecevemntratmtfpeucutahamtnexonicdeemrpaolitoafesoosspfnlneeootachllirssysofpdftfrnpraeeazlonahautntcntcbaxloneftoatecvoxdlxvnneedtiioigtegmtaheeatefaaeprrcrosheerrpalediengidrreouhvesuroztnsosinuiuiofprda',\n",
2321 " -1814.2525644323327)"
2324 "execution_count": 15,
2326 "output_type": "execute_result"
2330 "c8bl = ''.join([cadenus_letter(int(c, 2)) for c in chunks(c8b, 5)])\n",
2331 "c8bl, Pletters(c8bl)"
2335 "cell_type": "code",
2336 "execution_count": 16,
2342 "('afcaeuottacthrioletcserthshtrahkyorpfrgeoadppjnglternefeofiortsddoeeumscruernfetlaafstwientrvoonerhuahravereetsvsielhlostdoaloyaesmnndignnrhohhtsnaoilncnssicreanneeiiierwtanesrvogieiywssdgpvoiaisaoaeoaedrnitrnxeigrpsshadhdtoipaatexennesagrobtlesrnroirypbgedclliwalaleenigrrnwyrlimlpstoleftrdmuarieeeiiaolnewsaohrtlstobetnslvfivdovtpoaeeisciohipseveedtewfarnhebleaotohtttepnckaonhwetmvyprreonnasgdedoeeeoaamtcicttifnadresrtserosetrhcictpsaaehldhsfxsoaotctbbsoeirnsadlytrrunrceptthreuhnktaceceelrwnireeeaeseeeidisogceomnrtejhagabsenitlwtrnbmielsaretesrngsnhebiosdienafleisahocifevmfatanatrniagnhatnmibniufenrtottrnypaidyiegdnmerhhiotretcesseildrbceprigaesoadltahievebrcenlevasadnnthneiteiisahuhhuamonefyhlonwhaeeeeosneeyaneisetogyiterlihtcmioirarfdoetnihtnehiikamrdmnadanaodseseiyclsiantaoltciymidentthltndxtttmasbleaeetlisirtwturpfailteaoefeisiiiyisikvtwisprbsinelphrmohiagnlslvitodaisdpnyddcaaotahcehtueirredaectosnrhvnaodoikoetcineneurrisdcouraglvimmuppditeanditmaaiaieleonnreedaodboiumelrotntttgitnrlrienniklysogstcifypipvidvssmnceiasiitsnneatitomrhbnhnidprlrepoynalsnvsdosanesitfaenltgodatteeaisicrootmsmfhauenirsghynweintegodiileedtarnosrcaaendtcuttfdrbehtmfitoordruiaoyaanoeeldoinhusgiteaoriecevemntratmtfpeucutahamtnewonicdeemrpaolitoafesoosspfnlneeootachllirssxsofpdftfrnpraeeaylonahautntcntcbawloneftoatecvowdlwvnneedtiioigtegmtaheeatefaaeprrcrosheerrpalediengidrreouhvesuroytnsosinuiuiofprda',\n",
2343 " -1760.1126100904926)"
2346 "execution_count": 16,
2348 "output_type": "execute_result"
2352 "c8bl = ''.join([cadenus_letter(int(c, 2), doubled='z') for c in chunks(c8b, 5)])\n",
2353 "c8bl, Pletters(c8bl)"
2357 "cell_type": "code",
2358 "execution_count": 17,
2367 "execution_count": 17,
2369 "output_type": "execute_result"
2373 "max((cl for cl in string.ascii_lowercase),\n",
2374 " key=lambda l: Pletters(cadenus_letter(int(c, 2), doubled=l) for c in chunks(c8b, 5)))"
2378 "cell_type": "code",
2379 "execution_count": 18,
2385 "('afcaeuottacthrioletcserthshtrahkzorpfrgeoadppjnglternefeofiortsddoeeumscruernfetlaafstxientrvoonerhuahravereetsvsielhlostdoalozaesmnndignnrhohhtsnaoilncnssicreanneeiiierxtanesrvogieizxssdgpvoiaisaoaeoaedrnitrnyeigrpsshadhdtoipaateyennesagrobtlesrnroirzpbgedcllixalaleenigrrnxzrlimlpstoleftrdmuarieeeiiaolnexsaohrtlstobetnslvfivdovtpoaeeisciohipseveedtexfarnhebleaotohtttepnckaonhxetmvzprreonnasgdedoeeeoaamtcicttifnadresrtserosetrhcictpsaaehldhsfysoaotctbbsoeirnsadlztrrunrceptthreuhnktaceceelrxnireeeaeseeeidisogceomnrtejhagabsenitlxtrnbmielsaretesrngsnhebiosdienafleisahocifevmfatanatrniagnhatnmibniufenrtottrnzpaidziegdnmerhhiotretcesseildrbceprigaesoadltahievebrcenlevasadnnthneiteiisahuhhuamonefzhlonxhaeeeeosneezaneisetogziterlihtcmioirarfdoetnihtnehiikamrdmnadanaodseseizclsiantaoltcizmidentthltndytttmasbleaeetlisirtxturpfailteaoefeisiiizisikvtxisprbsinelphrmohiagnlslvitodaisdpnzddcaaotahcehtueirredaectosnrhvnaodoikoetcineneurrisdcouraglvimmuppditeanditmaaiaieleonnreedaodboiumelrotntttgitnrlrienniklzsogstcifzpipvidvssmnceiasiitsnneatitomrhbnhnidprlrepoznalsnvsdosanesitfaenltgodatteeaisicrootmsmfhauenirsghznxeintegodiileedtarnosrcaaendtcuttfdrbehtmfitoordruiaozaanoeeldoinhusgiteaoriecevemntratmtfpeucutahamtnexonicdeemrpaolitoafesoosspfnlneeootachllirssysofpdftfrnpraeeazlonahautntcntcbaxloneftoatecvoxdlxvnneedtiioigtegmtaheeatefaaeprrcrosheerrpalediengidrreouhvesuroztnsosinuiuiofprda',\n",
2386 " -1814.2525644323327)"
2389 "execution_count": 18,
2391 "output_type": "execute_result"
2395 "c8bl = ''.join([cadenus_letter(int(c, 2), doubled='v') for c in chunks(c8b, 5)])\n",
2396 "c8bl, Pletters(c8bl)"
2400 "cell_type": "code",
2401 "execution_count": 19,
2410 "execution_count": 19,
2412 "output_type": "execute_result"
2416 "min(c8bl), max(c8bl)"
2420 "cell_type": "code",
2421 "execution_count": 20,
2430 "execution_count": 20,
2432 "output_type": "execute_result"
2436 "len(c8bl), len(c8bl) / 25"
2440 "cell_type": "code",
2441 "execution_count": 21,
2447 "<matplotlib.axes._subplots.AxesSubplot at 0x7f37f275c390>"
2450 "execution_count": 21,
2452 "output_type": "execute_result"
2456 "image/png": "iVBORw0KGgoAAAANSUhEUgAAAXoAAAD7CAYAAABkO19ZAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDIuMS4yLCBodHRwOi8vbWF0cGxvdGxpYi5vcmcvNQv5yAAAEuhJREFUeJzt3X+05HVdx/HnK0gwxQBZiaPIiiFqhqtewU5iJGb4o5BKZFX8maslHs1OHVKTtMyfZBkFrUKAPxARSVT8wcGS/M1d2JYVJQGXXM623ESJYx4UfPfHfK8Ol3vvzJ2Zuz8++3ycM2e+3898P/N97/fOvOYzn5n5bqoKSVK7fmZ7FyBJWl4GvSQ1zqCXpMYZ9JLUOINekhpn0EtS4wx6SWqcQS9JjTPoJalxu2/vAgD222+/Wrly5fYuQ5J2KuvWrfufqloxaLsdIuhXrlzJ9PT09i5DknYqSW4cZjunbiSpcQa9JDXOoJekxhn0ktQ4g16SGmfQS1LjBgZ9krOS3JxkY1/b+UnWd5dNSdZ37SuT/KDvtjOWs3hJ0mDDfI/+bOA04NzZhqp61uxyklOBW/u2v76qVk2qQEnSeAYGfVVdnmTlfLclCXA88MTJltW2lSd/YsHbNr3laduwEkm7gnHn6I8EtlbVN/vaHpTkqiSfS3LkQh2TrEkynWR6ZmZmzDIkSQsZN+hXA+f1rW8BHlhVjwJeDXwgyX3m61hVa6tqqqqmVqwYeKoGSdKIRg76JLsDvwOcP9tWVbdX1Xe65XXA9cBDxi1SkjS6cUb0TwK+UVWbZxuSrEiyW7d8MHAIcMN4J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pXjF2WEl+jd6r/6eqd8rj+bY5aLH7GObB233YMvsZwGeH+eMneS29B03/k/D8qnrzEH0fSu+tWYDLqmrg285RdW8fj6P3QIXeFNPF9F7g1lbVc+ZsPxuguwOH0Bul3c7wb+O3iUn83Ufc7/uAhwJf46dTN1ULfKbT1+8a4BeBb7GE49l9qPn4bvXfq+qqIWrcLsdmW5nzIr8bveB+Y1WdNqDfm+k9Rxf8bGqBflNVNT2n7cSqeu8ifd5A76wAdzvWSR62nM/5u+1vRw/6HV33JDyyW718mCfh9tB9gDg7p/iFuQ/aOds2HRLjSnJtLfLh8CL95j2uu/rxHMWcY3kHsLWq7the9ezoDHppiZL8M/D2Id/yS9udQS8tUZKvAw9miVMw0vZi0EtL5BSMdjYGvSQ1boc9BYIkaTIMeklqnEEvSY0z6CWpcf8PFvkZRxhURioAAAAASUVORK5CYII=\n",
2458 "<matplotlib.figure.Figure at 0x7f37f2757470>"
2462 "output_type": "display_data"
2466 "freqs_8b = pd.Series(collections.Counter([l.lower() for l in c8bl if l in string.ascii_letters]))\n",
2467 "freqs_8b.plot(kind='bar')"
2471 "cell_type": "code",
2472 "execution_count": 22,
2478 "<matplotlib.axes._subplots.AxesSubplot at 0x7f37f26b4c50>"
2481 "execution_count": 22,
2483 "output_type": "execute_result"
2487 "image/png": "iVBORw0KGgoAAAANSUhEUgAAAY0AAAD7CAYAAACWq8i5AAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDIuMS4yLCBodHRwOi8vbWF0cGxvdGxpYi5vcmcvNQv5yAAAGXNJREFUeJzt3X+0XWV95/H3p1B+TAsSNKYsgsZOM1rK+ANSSFdtR6WFgJ2GTpXBtpJxKJkW7KLj9Ec67ZQR6xTbaW0Z23RYkhrUqaLVIa1gmhW11iqYIBQEyuIWZUgWQiT8cLTV4nznj/OkHq7nnPvckHAuyfu11lln7+9+nv3sc+6593P2j3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= pd.Series(english_counts)\n",
2498 "freqs.plot(kind='bar')"
2502 "cell_type": "code",
2503 "execution_count": 23,
2509 "['afcaeuottacthrioletcserthshtrahkzorpfrgeoadppjnglternefe',\n",
2510 " 'ofiortsddoeeumscruernfetlaafstxientrvoonerhuahravereetsv',\n",
2511 " 'sielhlostdoalozaesmnndignnrhohhtsnaoilncnssicreanneeiiie',\n",
2512 " 'rxtanesrvogieizxssdgpvoiaisaoaeoaedrnitrnyeigrpsshadhdto',\n",
2513 " 'ipaateyennesagrobtlesrnroirzpbgedcllixalaleenigrrnxzrlim',\n",
2514 " 'lpstoleftrdmuarieeeiiaolnexsaohrtlstobetnslvfivdovtpoaee',\n",
2515 " 'isciohipseveedtexfarnhebleaotohtttepnckaonhxetmvzprreonn',\n",
2516 " 'asgdedoeeeoaamtcicttifnadresrtserosetrhcictpsaaehldhsfys',\n",
2517 " 'oaotctbbsoeirnsadlztrrunrceptthreuhnktaceceelrxnireeeaes',\n",
2518 " 'eeeidisogceomnrtejhagabsenitlxtrnbmielsaretesrngsnhebios',\n",
2519 " 'dienafleisahocifevmfatanatrniagnhatnmibniufenrtottrnzpai',\n",
2520 " 'dziegdnmerhhiotretcesseildrbceprigaesoadltahievebrcenlev',\n",
2521 " 'asadnnthneiteiisahuhhuamonefzhlonxhaeeeeosneezaneisetogz',\n",
2522 " 'iterlihtcmioirarfdoetnihtnehiikamrdmnadanaodseseizclsian',\n",
2523 " 'taoltcizmidentthltndytttmasbleaeetlisirtxturpfailteaoefe',\n",
2524 " 'isiiizisikvtxisprbsinelphrmohiagnlslvitodaisdpnzddcaaota',\n",
2525 " 'hcehtueirredaectosnrhvnaodoikoetcineneurrisdcouraglvimmu',\n",
2526 " 'ppditeanditmaaiaieleonnreedaodboiumelrotntttgitnrlrienni',\n",
2527 " 'klzsogstcifzpipvidvssmnceiasiitsnneatitomrhbnhnidprlrepo',\n",
2528 " 'znalsnvsdosanesitfaenltgodatteeaisicrootmsmfhauenirsghzn',\n",
2529 " 'xeintegodiileedtarnosrcaaendtcuttfdrbehtmfitoordruiaozaa',\n",
2530 " 'noeeldoinhusgiteaoriecevemntratmtfpeucutahamtnexonicdeem',\n",
2531 " 'rpaolitoafesoosspfnlneeootachllirssysofpdftfrnpraeeazlon',\n",
2532 " 'ahautntcntcbaxloneftoatecvoxdlxvnneedtiioigtegmtaheeatef',\n",
2533 " 'aaeprrcrosheerrpalediengidrreouhvesuroztnsosinuiuiofprda']"
2536 "execution_count": 23,
2538 "output_type": "execute_result"
2542 "rows = chunks(c8bl, len(c8bl) // 25)\n",
2547 "cell_type": "code",
2548 "execution_count": 24,
2554 "['a..ae....a..h....e..se..hsh..ah....p...e.a.pp.....e..e.e',\n",
2555 " '......s...ee..s...e...e..aa.s...e.......e.h.ah.a.e.ee.s.',\n",
2556 " 's.e.h..s...a...aes.........h.hh.s.a......ss...ea..ee...e',\n",
2557 " '...a.es.....e...ss..p...a.sa.ae.ae........e...pssha.h...',\n",
2558 " '.paa.e.e..esa......es.......p..e......a.a.ee............',\n",
2559 " '.ps...e......a..eee..a...e.sa.h...s...e..s.........p.aee',\n",
2560 " '.s...h.pse.ee..e..a..he..ea...h...ep...a..h.e....p..e...',\n",
2561 " 'as..e..eee.aa..........a..es..se..se..h....psaaeh..hs..s',\n",
2562 " '.a......s.e...sa..........ep..h.e.h...a.e.ee......eeeaes',\n",
2563 " 'eee...s...e.....e.ha.a.se...........e.sa.e.es...s.he...s',\n",
2564 " '..e.a..e.sah....e...a.a.a....a..ha.........e.........pa.',\n",
2565 " '...e....e.hh....e..esse......ep...aes.a...ah.e.e...e..e.',\n",
2566 " 'asa....h.e..e..sah.hh.a...e..h....haeeee.s.ee.a.e.se....',\n",
2567 " '..e...h.......a....e...h..eh...a.....a.a.a..sese....s.a.',\n",
2568 " '.a.........e...h.........as..eaee...s.......p.a...ea.e.e',\n",
2569 " '.s.....s......sp..s..e.ph...h.a...s......a.s.p.....aa..a',\n",
2570 " 'h.eh..e...e.ae...s..h..a......e....e.e....s.....a.......',\n",
2571 " 'pp...ea.....aa.a.e.e....ee.a.......e................e...',\n",
2572 " '...s..s.....p.p....ss...e.as...s..ea......h..h...p...ep.',\n",
2573 " '..a.s..s..sa.es...ae......a..eea.s.......s..ha.e...s.h..',\n",
2574 " '.e...e......ee..a...s..aae...........eh............a..aa',\n",
2575 " '..ee.....h.s...ea...e.e.e....a....pe....aha...e......ee.',\n",
2576 " '.pa.....a.es..ssp....ee...a.h....ss.s..p......p.aeea....',\n",
2577 " 'aha.........a....e...a.e..........ee........e...aheea.e.',\n",
2578 " 'aaep.....shee..pa.e..e......e..h.es......s.s........p..a']"
2581 "execution_count": 24,
2583 "output_type": "execute_result"
2587 "chunks(''.join([l if l in 'phase' else '.' for l in c8bl]), 56)"
2591 "cell_type": "code",
2592 "execution_count": 25,
2598 "['aosriliaoeddaitihpkzxnraa',\n",
2599 " 'ffixppssaeizstascplneopha',\n",
2600 " 'cietascgoeeiaeoiedzaieaae',\n",
2601 " 'aolaatidtinedrlihislneoup',\n",
2602 " 'erhntooecdagnltittostlltr',\n",
2603 " 'utleelhdtifdniczuegnedinr',\n",
2604 " 'ososyeiobslnthiieasvgottc',\n",
2605 " 'tdsrefpeboemhtzsintsoiocr',\n",
2606 " 'tdtvntsesgiencmirdcddnano',\n",
2607 " 'aodonreeocsremikriioihfts',\n",
2608 " 'ceogedvoeeahiidvetfsiuech',\n",
2609 " 'teaismeaiohhtoetdmzalssbe',\n",
2610 " 'huleauearmoieinxaapnegoae',\n",
2611 " 'rmoigadmnncoirtieaieeioxr',\n",
2612 " 'iszzrrttsritiatscipsdtslr',\n",
2613 " 'ocaxoiecatfrsrhptavitesop',\n",
2614 " 'lresbexideeeaflroiitaapna',\n",
2615 " 'eusstefcljvthdtbsedfrofel',\n",
2616 " 'temdleatzhmcuonsnlvanrnfe',\n",
2617 " 'crngeirttafehedireseoiltd',\n",
2618 " 'snnpsinirgashtynhosnsenoi',\n",
2619 " 'efdvrahfratsuntevnmlrceae',\n",
2620 " 'reionoenubaeaitlnnntceetn',\n",
2621 " 'ttgirlbansnimhtparcgavoeg',\n",
2622 " 'hlnaonldrealotmhoeeoaeoci',\n",
2623 " 'saniieercntdnnardeidemtvd',\n",
2624 " 'harsrxaeeirreesmodaannaor',\n",
2625 " 'tfhazsosptnbfhboiastdtcxr',\n",
2626 " 'rsoopatrtliczilhkoittrhde',\n",
2627 " 'athaboottxaehieiodiecallo',\n",
2628 " 'hxheghhshtgplkaaebteutlxu',\n",
2629 " 'kitoerterrnroaegtosatmivh',\n",
2630 " 'zesadttrenhinmencinittrnv',\n",
2631 " 'onnecltoubagxrtliunsffsne',\n",
2632 " 'rtadlseshmtahdlsnmeidpses',\n",
2633 " 'prorltpenineamileeacreyeu',\n",
2634 " 'fviniontkemsensvnltrbusdr',\n",
2635 " 'rolixbcrtlioeaiierioecoto',\n",
2636 " 'gontaekhasbaedrtuotohufiz',\n",
2637 " 'encrltaccandeatortotttpit',\n",
2638 " 'oennanoierilonxdrnmmmadon',\n",
2639 " 'arsylsncceutsataitrsfhfis',\n",
2640 " 'dhseelhtetfanouisthmiatgo',\n",
2641 " 'puiievxpeeehedrsdtbftmfts',\n",
2642 " 'pacgnfeslsniespdcgnhotrei',\n",
2643 " 'jhrriitarrrezefpoihaonngn',\n",
2644 " 'nrepgvmaxntvasanutnurepmu',\n",
2645 " 'gaasrdvengoeneizrniedxrti',\n",
2646 " 'lvnsrozhistbeildardnroaau',\n",
2647 " 'tenhnvplrntriztdglpiunehi',\n",
2648 " 'ereaxtrdehrcsceclrrriieeo',\n",
2649 " 'reedzprheeneelaavilsacaef',\n",
2650 " 'neihroesebzntsoaiergodzap',\n",
2651 " 'etidlaofaiploieomnehzeltr',\n",
2652 " 'fsitienyeoaegaftmnpzaeoed',\n",
2653 " 'eveomensssivzneauionamnfa']"
2656 "execution_count": 25,
2658 "output_type": "execute_result"
2662 "columns = [''.join(c) for c in zip(*rows)]\n",
2667 "cell_type": "code",
2668 "execution_count": 26,
2968 " 'h': [(0, 12),\n",
3024 " 'n': [(0, 46),\n",
3132 " 'p': [(0, 35),\n",
3166 " 's': [(0, 20),\n",
3254 " 'v': [(1, 36),\n",
3280 "execution_count": 26,
3282 "output_type": "execute_result"
3286 "letter_positions = {letter: [(r, c) for r, row in enumerate(rows) for c, char in enumerate(row) if char == letter] \n",
3287 " for letter in deduplicate('phaseseven')}\n",
3292 "cell_type": "code",
3293 "execution_count": 27,
3326 "execution_count": 27,
3328 "output_type": "execute_result"
3332 "keycolumn = make_cadenus_keycolumn(reverse=True)\n",
3333 "inverse_keycolumn = {v: l for l, v in keycolumn.items()}\n",
3338 "cell_type": "code",
3339 "execution_count": 28,
3343 "def valid_partial_solution(solution, inverse_keycolumn):\n",
3344 " row_indices = [p[0] for p in sorted(solution, key=lambda x: x[1])]\n",
3345 " row_letters = [inverse_keycolumn[i] for i in row_indices]\n",
3346 " letter_pairs = ngrams(row_letters, 2)\n",
3347 " return all(p[0] <= p[1] for p in letter_pairs)"
3351 "cell_type": "code",
3352 "execution_count": 29,
3361 "execution_count": 29,
3363 "output_type": "execute_result"
3367 "solutions = [[p] for p in letter_positions['p']]\n",
3368 "for letter in 'ha': #'haseseven':\n",
3369 " new_solutions = []\n",
3370 " for solution in solutions:\n",
3371 " used_columns = [p[1] for p in solution]\n",
3372 " for position in letter_positions[letter]:\n",
3373 " if position[1] not in used_columns:\n",
3374 " if valid_partial_solution(solution + [position], inverse_keycolumn):\n",
3375 " new_solutions += [solution + [position]]\n",
3376 " solutions = new_solutions\n",
3381 "cell_type": "code",
3382 "execution_count": 30,
3391 "execution_count": 30,
3393 "output_type": "execute_result"
3397 "valid_partial_solution(solutions[1], inverse_keycolumn)"
3401 "cell_type": "code",
3402 "execution_count": 31,
3435 "execution_count": 31,
3437 "output_type": "execute_result"
3442 "for p in solutions[1]:\n",
3443 " this_column = columns[p[1]]\n",
3444 " rotated_column = this_column[p[0]:] + this_column[:p[0]]\n",
3445 " display += [rotated_column]\n",
3446 "display_rows = [''.join(r) for r in zip(*display)]\n",
3451 "cell_type": "code",
3452 "execution_count": 32,
3456 "def display_solution(solution, columns):\n",
3458 " for p in solution:\n",
3459 " this_column = columns[p[1]]\n",
3460 " rotated_column = this_column[p[0]:] + this_column[:p[0]]\n",
3461 " display += [rotated_column]\n",
3462 " return [''.join(r) for r in zip(*display)]"
3466 "cell_type": "code",
3467 "execution_count": 33,
3500 "execution_count": 33,
3502 "output_type": "execute_result"
3506 "display_solution(solutions[0], columns)"
3510 "cell_type": "code",
3511 "execution_count": 34,
3517 "-110.74748837196742"
3520 "execution_count": 34,
3522 "output_type": "execute_result"
3526 "sum(Ptrigrams(r) for r in display_rows)"
3530 "cell_type": "code",
3531 "execution_count": 35,
3535 "def score_solution(solution, columns):\n",
3537 " for p in solution:\n",
3538 " this_column = columns[p[1]]\n",
3539 " rotated_column = this_column[p[0]:] + this_column[:p[0]]\n",
3540 " display += [rotated_column]\n",
3541 " display_rows = [''.join(r) for r in zip(*display)]\n",
3542 " return sum(Ptrigrams(r) for r in display_rows)"
3546 "cell_type": "code",
3547 "execution_count": 36,
3553 "[([(0, 35), (0, 12), (0, 0)],\n",
3579 " -114.13063154833905),\n",
3580 " ([(0, 35), (0, 12), (0, 3)],\n",
3606 " -110.74748837196742),\n",
3607 " ([(0, 35), (0, 12), (0, 9)],\n",
3633 " -104.78169431178242),\n",
3634 " ([(0, 35), (0, 12), (0, 29)],\n",
3660 " -109.4716997212109),\n",
3661 " ([(0, 35), (0, 12), (0, 41)],\n",
3687 " -101.93339111217242),\n",
3688 " ([(0, 35), (0, 12), (1, 44)],\n",
3714 " -108.4937247934099),\n",
3715 " ([(0, 35), (0, 12), (1, 47)],\n",
3741 " -111.05157201209927),\n",
3742 " ([(0, 35), (0, 12), (2, 47)],\n",
3768 " -113.41085773377256),\n",
3769 " ([(0, 35), (0, 12), (3, 50)],\n",
3795 " -107.5080042911796),\n",
3796 " ([(0, 35), (0, 12), (4, 38)],\n",
3822 " -111.19702574254387)]"
3825 "execution_count": 36,
3827 "output_type": "execute_result"
3831 "[(s, display_solution(s, columns), score_solution(s, columns)) for s in solutions[:10]]"
3835 "cell_type": "code",
3836 "execution_count": 37,
3842 "[[(0, 35), (0, 12), (0, 41)],\n",
3843 " [(0, 35), (0, 12), (0, 9)],\n",
3844 " [(0, 35), (0, 12), (3, 50)],\n",
3845 " [(0, 35), (0, 12), (1, 44)],\n",
3846 " [(0, 35), (0, 12), (0, 29)],\n",
3847 " [(0, 35), (0, 12), (0, 3)],\n",
3848 " [(0, 35), (0, 12), (1, 47)],\n",
3849 " [(0, 35), (0, 12), (4, 38)],\n",
3850 " [(0, 35), (0, 12), (2, 47)],\n",
3851 " [(0, 35), (0, 12), (0, 0)]]"
3854 "execution_count": 37,
3856 "output_type": "execute_result"
3860 "sorted(solutions[:10], key=lambda s: score_solution(s, columns), reverse=True)"
3864 "cell_type": "code",
3865 "execution_count": 38,
3869 "solutions = sorted(solutions, key=lambda s: score_solution(s, columns), reverse=True)[:10000]"
3873 "cell_type": "code",
3874 "execution_count": 39,
3878 "# for letter in 'seseven': #'haseeight':\n",
3879 "# new_solutions = []\n",
3880 "# for solution in solutions:\n",
3881 "# used_columns = [p[1] for p in solution]\n",
3882 "# for position in letter_positions[letter]:\n",
3883 "# if position[1] not in used_columns:\n",
3884 "# if valid_partial_solution(solution + [position], inverse_keycolumn):\n",
3885 "# new_solutions += [solution + [position]]\n",
3886 "# solutions = sorted(new_solutions, key=lambda s: score_solution(s, columns), reverse=True)[:10000]\n",
3891 "cell_type": "code",
3892 "execution_count": 40,
3925 "execution_count": 40,
3927 "output_type": "execute_result"
3931 "display_solution(solutions[0], columns)"
3935 "cell_type": "code",
3936 "execution_count": 41,
3945 "execution_count": 41,
3947 "output_type": "execute_result"
3951 "hinted_keywords = [w for w in keywords if w[0] =='f' if len(transpositions_of(w)) == 7]\n",
3952 "len(hinted_keywords)"
3956 "cell_type": "code",
3957 "execution_count": 42,
3975 "execution_count": 42,
3977 "output_type": "execute_result"
3981 "hinted_keywords[:10]"
3985 "cell_type": "code",
3986 "execution_count": 43,
3995 "execution_count": 43,
3997 "output_type": "execute_result"
4001 "first_chunk = c8bl[:175]\n",
4006 "cell_type": "code",
4007 "execution_count": 44,
4013 "['gatlrlnjtonethnirreh',\n",
4014 " 'raorejnptreanhriaeso',\n",
4015 " 'raohoanptraesrriasul',\n",
4016 " 'raohhanptraemrriasln',\n",
4017 " 'raorhaeptrnemsrianln',\n",
4018 " 'raonlneptrnissriaaoc',\n",
4019 " 'garhrarjtartsnnifphn',\n",
4020 " 'raoaalapteesnfriunnr',\n",
4021 " 'raonanhpterfrariutpn',\n",
4022 " 'garehhrjteaaraniessp',\n",
4023 " 'raonhalpterafnriutsp',\n",
4024 " 'fainrleptorniseirtno',\n",
4025 " 'raoaanhptemfrariunpn',\n",
4026 " 'raloannptirsrhrioalt',\n",
4027 " 'falmireptinonseiosrn',\n",
4028 " 'ralhaanptiafmrriospn',\n",
4029 " 'faeilenptnoisreirroo',\n",
4030 " 'raeoeanptneafhrirusp',\n",
4031 " 'earotktntvrugheivarj',\n",
4032 " 'gaeorhojtarernnisaep',\n",
4033 " 'gaeorhnjtarerhnisaep',\n",
4034 " 'raeooaeptareesrisaun',\n",
4035 " 'garnahrjtvenranivrep',\n",
4036 " 'raalaenptmifsrrinopo',\n",
4037 " 'faoeoepptnneareihrus',\n",
4038 " 'falhonpptnaerreirsut',\n",
4039 " 'fanroanpthiesreiaoul',\n",
4040 " 'fanhonpptraerreinsut',\n",
4041 " 'rahnaanptaofmrrisepn',\n",
4042 " 'fahrrinptaitoreisohh',\n",
4043 " 'rarrjaaptnensfrineon',\n",
4044 " 'gaaohrmjtsrrnnninapn',\n",
4045 " 'gaaarhrjtsenraninnnp',\n",
4046 " 'gasrlhrjtntnraniehrp',\n",
4047 " 'fasanomptnensneieean',\n",
4048 " 'raalrempftinsnrpiono',\n",
4049 " 'raaorejpftneanrpihes',\n",
4050 " 'ghrrlanjratnthnpfhri',\n",
4051 " 'gharnarjreaetvnpnfai',\n",
4052 " 'frtroenppxthsredoheo',\n",
4053 " 'frahoepppeaearednsus',\n",
4054 " 'raeaoalpfnsntirprlhi',\n",
4055 " 'raaiahnpfmotarrpnhis',\n",
4056 " 'froiianppnoosredhhrl',\n",
4057 " 'rahrinnpfaeeorrpsere',\n",
4058 " 'rahaaiupfaeselrpsnlr',\n",
4059 " 'raaerejpfsreanrpnpes',\n",
4060 " 'graeohnjetarrhneisap',\n",
4061 " 'fitahanpoimesrerenln',\n",
4062 " 'grtaaahjeosntrnernei',\n",
4063 " 'rotaaanpeosetrrurnni',\n",
4064 " 'roieaaopeeanfnrureep',\n",
4065 " 'rrejahnpernfarrepops',\n",
4066 " 'rrejarepernfnsrepopn',\n",
4067 " 'fopalrnpertntheuiirh',\n",
4068 " 'frpnhrlperoapneeiesd',\n",
4069 " 'foperehpernpaaeuirds',\n",
4070 " 'fopalaapersnteeuinri',\n",
4071 " 'rrjalaepensnfrreonrp',\n",
4072 " 'fopaarnpersmpreuinnd',\n",
4073 " 'roatalhpeeifnarunepr',\n",
4074 " 'gtfiehrjuterranrrrep',\n",
4075 " 'rrainanpeneofhreerep',\n",
4076 " 'filhranpoiapmrerosdn',\n",
4077 " 'rrrajaapevtnnfrevioe',\n",
4078 " 'roeaaanpeatefhrusinp',\n",
4079 " 'rreinanpeaeofhresrep',\n",
4080 " 'ronealnperrfnhrutppr',\n",
4081 " 'fioraenpohpmsreredno',\n",
4082 " 'fonprlnperrpnheutidr',\n",
4083 " 'finlrenporipsrertodo',\n",
4084 " 'rrlatajpenfisnrerpen',\n",
4085 " 'rooaeaepenfntaruhpri',\n",
4086 " 'fiairnhpomopraernhdn',\n",
4087 " 'pfomrteddsnnxstcnsno',\n",
4088 " 'rrninalpeheofnrearep',\n",
4089 " 'fonrraeperipmseunodn',\n",
4090 " 'fonrnrhperirpaeunotd',\n",
4091 " 'pfnsoaiddsoseetccrne',\n",
4092 " 'grnatahjeetonrnesire',\n",
4093 " 'grnarhrjeetnranesinp',\n",
4094 " 'ronarampeetnfnrusinp',\n",
4095 " 'roaaeaepeifresrueppn',\n",
4096 " 'finnnorpoesnsperscan',\n",
4097 " 'rosaanmpeoftnnrurpia',\n",
4098 " 'flapannpitrsrheoiilt',\n",
4099 " 'raaeoaopntaefnreieup',\n",
4100 " 'faaeorppntaevreeieuv',\n",
4101 " 'eaattktnntrogheeivrj',\n",
4102 " 'gaanthnjeteorhnniarp',\n",
4103 " 'rlaealnpitnfnhroirpr',\n",
4104 " 'faanorppeteevreniauv',\n",
4105 " 'raaejanpetanfhrnisop',\n",
4106 " 'gaarehrjntvaraneivep',\n",
4107 " 'raaeuaopetalfnrnisip',\n",
4108 " 'faaooeppetnearenihus',\n",
4109 " 'gaanehrjnthrraneiaep',\n",
4110 " 'raannalpethofnrniaep',\n",
4111 " 'eaahtktnntaogheeisrj',\n",
4112 " 'ftaaormpxtshnneoinen',\n",
4113 " 'ftashanpxtnemreoieln',\n",
4114 " 'ftashnapxtnenmeoiela',\n",
4115 " 'faasoeppetnearenieus',\n",
4116 " 'faaeoeppetsearenious',\n",
4117 " 'farnorppepeevrendauv',\n",
4118 " 'farnonrpepeehiendaua',\n",
4119 " 'farnoeppepeearendsus',\n",
4120 " 'gfrirhrjteearanrernp',\n",
4121 " 'raoieaopneeafnreurep',\n",
4122 " 'paoprhndeeeiartnufos',\n",
4123 " 'paoprredeeeinstnufon',\n",
4124 " 'faoeirnpeeaeihenusro',\n",
4125 " 'raolhaepeenafrrnursp',\n",
4126 " 'gaaahhrjestarannlisp',\n",
4127 " 'rlrahalpittafnrohisp',\n",
4128 " 'gaviehrjnvearaneorep',\n",
4129 " 'raaoorapesneatrnlhuf',\n",
4130 " 'flaoinrpisnorpeolhrt',\n",
4131 " 'ptrlfondxtndhhtohrce',\n",
4132 " 'pthafnhdxemdratolncn',\n",
4133 " 'ftrhnaipxtartoeohsni',\n",
4134 " 'rlaaniapissrefrolntr',\n",
4135 " 'rlralaepitsnfrrohnrp',\n",
4136 " 'rlraraepitsnfrrohnnp',\n",
4137 " 'fthsranpxenpmreoledn',\n",
4138 " 'fthnraepxeapmseolidn',\n",
4139 " 'plasinpdisnoretolert',\n",
4140 " 'rlnaniepinfresroaptr',\n",
4141 " 'faauirlpeslopnennird',\n",
4142 " 'raaeuaepesalfrrnnsip',\n",
4143 " 'flnnrrepinrtpseoatxd',\n",
4144 " 'faaeuirpesalopennsir',\n",
4145 " 'ptnocemdxnhesntoaeto',\n",
4146 " 'raannaepesrofrrnnnep',\n",
4147 " 'flanrrapisripmeonnod',\n",
4148 " 'ftamrropxsnnpseonsnd',\n",
4149 " 'plarinpdisnoretonnrt',\n",
4150 " 'plnninpdineoretoasrt',\n",
4151 " 'pleinpndisorertoortf',\n",
4152 " 'ftehnrapxseapmeoolid',\n",
4153 " 'fvaaoeppvteeareoinus',\n",
4154 " 'raaeoaopstnefnrlirup',\n",
4155 " 'fvaeoeppvtneareoirus',\n",
4156 " 'grianhrjtesrranhrnnp',\n",
4157 " 'fhpaarepertmnseliinn',\n",
4158 " 'raotaanpseiefhrluenp',\n",
4159 " 'rronhaepterafrrhunsp',\n",
4160 " 'rrlealnptirfnhrhoppr',\n",
4161 " 'fvaeoeppvereareonpus',\n",
4162 " 'frlprlnptirpnhehoidr',\n",
4163 " 'rvarajapvnetnfroeeio',\n",
4164 " 'raaoahapseetafrlnuis',\n",
4165 " 'frxrohnptopharehades',\n",
4166 " 'rroeanhpthrfrarheppn',\n",
4167 " 'ranelanpsrrifhrltpop',\n",
4168 " 'rroeaanpthrsfrrhepnp',\n",
4169 " 'gaoanhrjsnteranlhirp',\n",
4170 " 'rrlajanptntnfhrhriop',\n",
4171 " 'grlaehrjtntsranhriop',\n",
4172 " 'eaotatknsnothgelhrir',\n",
4173 " 'rrltornptnieahrhreuf',\n",
4174 " 'rhliatnpenefhhrlrrpa',\n",
4175 " 'faoionppsneerrelhrut',\n",
4176 " 'raornaepsnaotnrlhfei',\n",
4177 " 'faoeonppsnrerrelhput',\n",
4178 " 'faoropnpsnperrelhdui',\n",
4179 " 'raoaianpsnfotrrlhphi',\n",
4180 " 'rhaanaspemfrtnrlnpni',\n",
4181 " 'rrljasaptnntnfrhroie',\n",
4182 " 'fhaprhnpemrparelnids',\n",
4183 " 'frlposrptnrenpehriue',\n",
4184 " 'paouinpdsnloretlhirt',\n",
4185 " 'frliatnptnotxhehrhio',\n",
4186 " 'frlxaohptnothaehraie',\n",
4187 " 'rrliahaptnotafrhrhis',\n",
4188 " 'fhaxahnpemotarelnais',\n",
4189 " 'raoeooapsnnertrlhrua',\n",
4190 " 'paoiinpdsnooretlhhrt',\n",
4191 " 'frliataptnosxtehrhno',\n",
4192 " 'rrlnauaptnhtlfrhraii',\n",
4193 " 'fhahirnpemaoprelnsrd',\n",
4194 " 'fharaorpemnsapelnnne',\n",
4195 " 'fhasrorpemnpanelnede',\n",
4196 " 'fhatrmrpesxpnnelnods',\n",
4197 " 'paalinpdssioretlnort',\n",
4198 " 'rraoealptshrfnrhnepp',\n",
4199 " 'fhnoeaepenarmselaepn',\n",
4200 " 'paaoremdessnfntennnd',\n",
4201 " 'paslinpdsnioretleort',\n",
4202 " 'fhnirmrpeeopnnelsrds',\n",
4203 " 'frnrailptentoiehsnir',\n",
4204 " 'roajraapntnenfrhioee',\n",
4205 " 'faailrepmtoinseniron',\n",
4206 " 'foaeoeppntnearehirus',\n",
4207 " 'glanohnjntrrrhnritap',\n",
4208 " 'rlanoonpntrrehrritau',\n",
4209 " 'goaeehrjntaaranhisep',\n",
4210 " 'roaeuaapntalferhisip',\n",
4211 " 'roaeeoapntaaefrhiseu',\n",
4212 " 'flanrlepntrtiseritxo',\n",
4213 " 'rlanhoopntraerrritsu',\n",
4214 " 'faaapnrpmtsroneninie',\n",
4215 " 'flaeonppntserreriout',\n",
4216 " 'glhrranjnreathnrpefi',\n",
4217 " 'flrrpnhpnperoaerdeie',\n",
4218 " 'flrxrohpnpothaerdahe',\n",
4219 " 'rlaninnpnfreohrrptre',\n",
4220 " 'forosimpspaoenenderu',\n",
4221 " 'farnrlepmpriisendnoo',\n",
4222 " 'goratahjnetonrnheire',\n",
4223 " 'raoraenpmeatsrrnufio',\n",
4224 " 'rlrejanpnernfhrrepop',\n",
4225 " 'gorhraejneratanhepfi',\n",
4226 " 'glrhranjnerathnrepfi',\n",
4227 " 'rloanenpnefrrhrruptp',\n",
4228 " 'rlrjahapnentafrreois',\n",
4229 " 'paoprhndmeeiartnufos',\n",
4230 " 'rorejaepneanfrrhesop',\n",
4231 " 'flonprnpnerrpherutid',\n",
4232 " 'rloneaepnehafrrruaep',\n",
4233 " 'foapianpnsrotrehlihi',\n",
4234 " 'foapirnpnsroprehlihd',\n",
4235 " 'flrliinpntioeherhorr',\n",
4236 " 'flrohatpnthatxerhesi',\n",
4237 " 'rlrohaepnthafrrrhesp',\n",
4238 " 'rahnhaepmerafrrnlnsp',\n",
4239 " 'rlrhnaepntaofrrrhsep',\n",
4240 " 'rlrsoaepntnhfrrrheep',\n",
4241 " 'raaoraepmsenfrrnnunp',\n",
4242 " 'raonnrapsroretrnaene',\n",
4243 " 'raiuaanpselfmrrnripn',\n",
4244 " 'faieoeppseaearenreus',\n",
4245 " 'faraoeppspeearendnus',\n",
4246 " 'falaninpsitrorenoitr',\n",
4247 " 'fatnrirpsxrtopenonhh',\n",
4248 " 'paerhomdstneantnvnle',\n",
4249 " 'gantahrjseierannaenp',\n",
4250 " 'raetlalpsniifnrnreop',\n",
4251 " 'raetlanpsniifrrnreop',\n",
4252 " 'faoirhapsaenemenernl',\n",
4253 " 'raoeaanpshrfmrrneppn',\n",
4254 " 'ranalalpsrfntirntpri',\n",
4255 " 'fanpaoepsrrserentilu',\n",
4256 " 'fanuirlpsrlopnentird',\n",
4257 " 'faatonrpsmierienneun',\n",
4258 " 'pallinpdsnioretnrort',\n",
4259 " 'paltropdsnxthetnrohe',\n",
4260 " 'galnaohjsnrtrrnnrtia',\n",
4261 " 'paaoinedsmhorftnnern',\n",
4262 " 'fnonisrpnssonpeancre',\n",
4263 " 'ranotaapsreiefrnnuen',\n",
4264 " 'famriaopsnnothensnri',\n",
4265 " 'famriropsnnopsensnrd',\n",
4266 " 'pnnsiopdnsoohetacrre',\n",
4267 " 'ratalrnptositnrirnoh',\n",
4268 " 'ealktvanttgovseihjro',\n",
4269 " 'gaoharajtrrnelniapee',\n",
4270 " 'gaorahfjtrenrtniaeep',\n",
4271 " 'raooathptreeuariaunr',\n",
4272 " 'raorrhtptrntanrianhs',\n",
4273 " 'faoatolpteeuaeeiunre',\n",
4274 " 'failnraptoirtleironh',\n",
4275 " 'raonhanpterafrriutsp',\n",
4276 " 'rarojaaptennsfriehol',\n",
4277 " 'raolnanptenrfhriurtp',\n",
4278 " 'failthoptonheneirral',\n",
4279 " 'faionoiptosarneirnis',\n",
4280 " 'faorrasptenilceiunoe',\n",
4281 " 'fatlvnnptxivnseioooa',\n",
4282 " 'gaaavlajtenvcfnineoe',\n",
4283 " 'ralnahnptirfasrionps',\n",
4284 " 'falmireptinonseiosrn',\n",
4285 " 'gaahhlajtearnfninspr',\n",
4286 " 'ranoafrpteeedariaunc',\n",
4287 " 'ranrnnapteehofriaeae',\n",
4288 " 'ranonfcptrrtdhritsnc',\n",
4289 " 'raeooasptarelcrisaue',\n",
4290 " 'raeoeroptarsehrisaoe',\n",
4291 " 'raoenuvptnnohurihrec',\n",
4292 " 'raoeluvptnnihurihroc',\n",
4293 " 'galavlajtnmvcfnirnoe',\n",
4294 " 'raahnanptmaofrrinsep',\n",
4295 " 'ganorctjthrehxniaaeo',\n",
4296 " 'fanroanpthiesreiaoul',\n",
4297 " 'ganhhnajtrarrfninspt',\n",
4298 " 'ranhaozptrafherinspe',\n",
4299 " 'fahattmptacxuneiseor',\n",
4300 " 'gahehfhjtarrtonisepo',\n",
4301 " 'gahehlajtarrnfnisepr',\n",
4302 " 'fanlnifptnisoteiaocr',\n",
4303 " 'faamriaptsnnoceinsnr',\n",
4304 " 'raalnripftnhtorpirah',\n",
4305 " 'ghanrtajrtheonnpiaer',\n",
4306 " 'raahnzlpftaoenrpisen',\n",
4307 " 'raarnzopftnoenrpinen',\n",
4308 " 'gharaaajrtnsmfnpinnn',\n",
4309 " 'raaraozpftnsserpinnn',\n",
4310 " 'ghtanaojromntnnprnai',\n",
4311 " 'ghrosefjraozttnpfgdt',\n",
4312 " 'ghrraocjraamdhnpflns',\n",
4313 " 'ozkrtcsgegaiatfnjfel',\n",
4314 " 'ekhrtulngraiheejpfec',\n",
4315 " 'rarstolpfpzuherpdere',\n",
4316 " 'frzltolppeiuaeednore',\n",
4317 " 'ghaatoojrnfsdrnpepzs',\n",
4318 " 'gharooojrnerdrnpeeas',\n",
4319 " 'raaoithpfeeeuarpnurr',\n",
4320 " 'raafontpfesrturpnrsn',\n",
4321 " 'frlanirppisroaedoltr',\n",
4322 " 'friintnppooruhedhrtr',\n",
4323 " 'raeirolpfaeeherpsree',\n",
4324 " 'fraxkrrppmogvnednajv',\n",
4325 " 'ghonavhjrnrtuonphtir',\n",
4326 " 'frloiroppnnaeaedrhae',\n",
4327 " 'raankrspfmaghtrpnije',\n",
4328 " 'frosanappsnenmedneea',\n",
4329 " 'rahrinopfaeeoorpsere',\n",
4330 " 'frszoteppnesugedennr',\n",
4331 " 'raeniaepfsrotarpothi',\n",
4332 " 'granoahjethrsrneiaal',\n",
4333 " 'fiihrhepoeaeeaerrsel',\n",
4334 " 'roeseooperztonrupevg',\n",
4335 " 'roeaathperfeuaruppnr',\n",
4336 " 'grtaooujehsrdhnernas',\n",
4337 " 'roaaeoopeferonrupnpg',\n",
4338 " 'rraaesopefnrmhrepepn',\n",
4339 " 'rraeesspefarmnrepspn',\n",
4340 " 'roalizfpefneetruprrn',\n",
4341 " 'roaaionpefmeohrupnrg',\n",
4342 " 'fopalrrpersneheuinre',\n",
4343 " 'frainsopeneomaeeeren',\n",
4344 " 'roaaranpeefvterunpvi',\n",
4345 " 'filanvspoieevzeronao',\n",
4346 " 'fileoonpoindoherorsg',\n",
4347 " 'roatsecpenrrteruevht',\n",
4348 " 'roahalrpeeafnprunspr',\n",
4349 " 'foahroopeeaidoeunsos',\n",
4350 " 'roahlaipeeanthrunsri',\n",
4351 " 'roeaasapeatemirusinn',\n",
4352 " 'finaltnportiuhertior',\n",
4353 " 'finalthportiuaertior',\n",
4354 " 'roeaasxpeatemfrusinn',\n",
4355 " 'etravehnuvtuhrervirk',\n",
4356 " 'greavlrjeatutanesirh',\n",
4357 " 'rrejaorpeanfnpresoph',\n",
4358 " 'rresserpeamnfpresntd',\n",
4359 " 'fonsetopermgooeutnhd',\n",
4360 " 'fiotdeopohuotnererot',\n",
4361 " 'fintdkfporuogtertroj',\n",
4362 " 'roeaavtpeaeturrusnir',\n",
4363 " 'rolaaatpenftmrrurpin',\n",
4364 " 'grohtaajenrotnnehpri',\n",
4365 " 'rooataepenfisnruhpel',\n",
4366 " 'fiargfipompjteerndnr',\n",
4367 " 'fiargvapompjvierndno',\n",
4368 " 'rolahsepenfaztrurpsd',\n",
4369 " 'rolasaapenfnterurpei',\n",
4370 " 'rolasrhpenfnterurpeh',\n",
4371 " 'filrsroponpntserrdeh',\n",
4372 " 'filinrnponorpherrhtd',\n",
4373 " 'rolesatpennntarurrei',\n",
4374 " 'ronoaafperrtetrunain',\n",
4375 " 'fonrraeperipmseunodn',\n",
4376 " 'fonrnrhperirpaeunotd',\n",
4377 " 'fonrharperiateeunosi',\n",
4378 " 'ronnstrperhcaprunaei',\n",
4379 " 'rosaorfpenfgtsruepfh',\n",
4380 " 'fonarropeetneaeusine',\n",
4381 " 'finarrhpoetneeersine',\n",
4382 " 'ronantipeetsuirusicr',\n",
4383 " 'gaattirjntotoaneirsr',\n",
4384 " 'raajvaepetnostrniool',\n",
4385 " 'flaplerpitrntveoiirt',\n",
4386 " 'faareoopntvaeaeeiveu',\n",
4387 " 'raaveftpntoutsreiolo',\n",
4388 " 'rlatroopithionroiatg',\n",
4389 " 'faavetopetoluaenioor',\n",
4390 " 'raannalpethofnrniaep',\n",
4391 " 'raannanpetrofhrninep',\n",
4392 " 'faanrofpetrieteninou',\n",
4393 " 'rlahoelpitartnroisat',\n",
4394 " 'faahgtepetajugenisnr',\n",
4395 " 'gaahehfjntarrtneisep',\n",
4396 " 'rlahnanpitarfrroistp',\n",
4397 " 'rlahizepitahearoisin',\n",
4398 " 'rlahizlpitahenroisin',\n",
4399 " 'rlarizopitnhenroinin',\n",
4400 " 'faahntopetatuaenisnr',\n",
4401 " 'ftahnrspxtattleoisnh',\n",
4402 " 'rlarsetpitnntaroinet',\n",
4403 " 'flaarimpitsnoneoinnr',\n",
4404 " 'gaannhajeterrfnnisnp',\n",
4405 " 'raartsopnfpsmhrepdzn',\n",
4406 " 'farrntopepatuaendlnr',\n",
4407 " 'farnonrpepeehiendaua',\n",
4408 " 'farnroopephieoendaou',\n",
4409 " 'raahinopefaeoornpsre',\n",
4410 " 'raaaotfpefieitrnpeue',\n",
4411 " 'flrnriepipenoneodsnr',\n",
4412 " 'rlannaapifenmtropsan',\n",
4413 " 'faoiesopneeamaeeuren',\n",
4414 " 'flienoopionhdoeorras',\n",
4415 " 'flinhoopioradoeortss',\n",
4416 " 'fliseerpiolstveorlst',\n",
4417 " 'fliteoopiohsoneorasg',\n",
4418 " 'fliteonpiohsoheorasg',\n",
4419 " 'plilhrvdionaeutorrse',\n",
4420 " 'favhhtopevekuaenosgr',\n",
4421 " 'plavdrvdisveeutologe',\n",
4422 " 'flrvtoopitvcdoeohoas',\n",
4423 " 'flrseorpitledaeohlds',\n",
4424 " 'flrseorpitledaeohlds',\n",
4425 " 'plavervdisoeeutolode',\n",
4426 " 'rlaoanipisnfrerolhpt',\n",
4427 " 'flrliefpitnorteohrrp',\n",
4428 " 'pthafnhdxemdratolncn',\n",
4429 " 'planervdishgeutolahe',\n",
4430 " 'ftrhnaipxtartoeohsni',\n",
4431 " 'rlrsalrpitnfnprohepr',\n",
4432 " 'faatctopesieuaennehr',\n",
4433 " 'ftnronfpxnphsteoadec',\n",
4434 " 'flnierhpinoreaeoarpe',\n",
4435 " 'paaeuivdesaloutnnsir',\n",
4436 " 'raalofrpesnsdprnnrnc',\n",
4437 " 'flaadoopismedoeonngs',\n",
4438 " 'flamrrnpisnipreonsod',\n",
4439 " 'ftamrropxsnnpseonsnd',\n",
4440 " 'ftardkapxsnogmeonnoj',\n",
4441 " 'ftnndkopxnsogneoacoj',\n",
4442 " 'rletaropishtiorooait',\n",
4443 " 'flemrropisnipoeoosod',\n",
4444 " 'grianeajtesrgfnhrnnh',\n",
4445 " 'rajtvsvpsnivcurloeoe',\n",
4446 " 'frpjoonptrndohehiosg',\n",
4447 " 'prpraordteissvthfoln',\n",
4448 " 'prinhovdtoraeuthrnsu',\n",
4449 " 'rrlranoptiatarrhofii',\n",
4450 " 'palrnrvdsithtutloxah',\n",
4451 " 'raianhrpsofraprlhpts',\n",
4452 " 'rrorarrpthatvnrhefiv',\n",
4453 " 'fveeaoopvareeaeospnu',\n",
4454 " 'ranhaovpsrateurltsiu',\n",
4455 " 'fhafzoipeeseneelernh',\n",
4456 " 'rrhfaiuptetiehrhlrhr',\n",
4457 " 'rrvdapoptvoceorhooef',\n",
4458 " 'prvgovgdtvheuftholur',\n",
4459 " 'frvgsaeptvhrcaeholhe',\n",
4460 " 'rhahirepesaiptrllsed',\n",
4461 " 'rrlajaoptntnfnrhriop',\n",
4462 " 'faoaponpsntrerelhiiu',\n",
4463 " 'grlthaojtnortnnhrrpi',\n",
4464 " 'rrliaatptneflnrhrrpe',\n",
4465 " 'rhliatnpenefhhrlrrpa',\n",
4466 " 'rrlaaotptnftsrrhrpin',\n",
4467 " 'gaoherfjsnrrptnlhped',\n",
4468 " 'frlrlhlptnpireehrdop',\n",
4469 " 'raoaahepsnfeehrlhpns',\n",
4470 " 'fharxanpemposhelndal',\n",
4471 " 'raoanaipsnfrtorlhpti',\n",
4472 " 'rhaanhrpemfraprlnpns',\n",
4473 " 'faormropespnnneendsn',\n",
4474 " 'rrlahhfptnfaesrhrpsl',\n",
4475 " 'rrlasaoptnfntsrhrpei',\n",
4476 " 'fharshepempnraelndep',\n",
4477 " 'fhaphsrpemdrmnelntpn',\n",
4478 " 'fhaproipemrpneelnidh',\n",
4479 " 'prlrlfadtntidlthrxoc',\n",
4480 " 'frliatfptnotxtehrhio',\n",
4481 " 'frlirdfptnopetehrhdg',\n",
4482 " 'frlitrnptnoxphehrhod',\n",
4483 " 'frlxvzaptnovdcehraoo',\n",
4484 " 'rrlnauaptnhtlfrhraii',\n",
4485 " 'rhansaapemrnftrlnnep',\n",
4486 " 'frlhorgptnaephehrsud',\n",
4487 " 'fhahscepemazaaelnsdl',\n",
4488 " 'rhasathpemntaorlneii',\n",
4489 " 'rhnhaarperafmprlnspn',\n",
4490 " 'rraoataptsrtnnrhnair',\n",
4491 " 'fratornptsxhprehnoed',\n",
4492 " 'faaneoopssrreaelntpu',\n",
4493 " 'fraoraiptshntoehneni',\n",
4494 " 'fhaanaspesmrerelnnne',\n",
4495 " 'fhaarrhpesmnprelnnnd',\n",
4496 " 'frnplaopterissehsiol',\n",
4497 " 'frnrhfopteiesoehsolr',\n",
4498 " 'frnratrpteisnhehsolr',\n",
4499 " 'raaohaapmtracnrniase',\n",
4500 " 'gaaoradjmtrnsenniann',\n",
4501 " 'goaeorojntareanhisae',\n",
4502 " 'foaeeoopntaaeaehiseu',\n",
4503 " 'foaeuaipntaleoehisin',\n",
4504 " 'raasoalpmtoefnrnirup',\n",
4505 " 'glasntajntoexfnrirto',\n",
4506 " 'raasaeopmtoatornircv',\n",
4507 " 'gohieaajnreanfnhpree',\n",
4508 " 'rlaiuarpnfelearrprin',\n",
4509 " 'gohraocjnramdhnhpfns',\n",
4510 " 'glhraosjnramdtnrpfns',\n",
4511 " 'gohassujnrfzrhnhppeh',\n",
4512 " 'rlarshtpnfpzerrrpdel',\n",
4513 " 'gohztuvjnreohunhpndc',\n",
4514 " 'roakfrfpnfgttsrhpjuh',\n",
4515 " 'flrkrolpnpgeaeerdjee',\n",
4516 " 'gohzahfjnrenetnhpnes',\n",
4517 " 'rlakserpnfgrtvrrpjht',\n",
4518 " 'faronvlpmpotvcendgno',\n",
4519 " 'roaoooipsfosrnrnpgns',\n",
4520 " 'flrraropnpaaeaerdlce',\n",
4521 " 'rlaninrpnfreoarrptre',\n",
4522 " 'rlanrnopnfratdrrptln',\n",
4523 " 'rlansorpnfroeprrptru',\n",
4524 " 'farosiopmphoooenderr',\n",
4525 " 'farlahepmposraendsnp',\n",
4526 " 'flrnrizpnphioeerdaoh',\n",
4527 " 'flrhnropnpateaerdsne',\n",
4528 " 'farrshdpmpnneeendnel',\n",
4529 " 'fliihrhpnoeaeeerrrse',\n",
4530 " 'floposfpnerdzteruise',\n",
4531 " 'pafnrofdmdrtettncnxu',\n",
4532 " 'plinurvdnohleutrraie',\n",
4533 " 'rlosnerpneoetprrurtv',\n",
4534 " 'faisafopmooasoenrrcr',\n",
4535 " 'flrohirpnthaoperhesr',\n",
4536 " 'plrohivdnthaoutrhesr',\n",
4537 " 'fahnhtipmeraioenlnse',\n",
4538 " 'fahnhirpmeraopenlnsr',\n",
4539 " 'flrhrorpntaieperhsou',\n",
4540 " 'plrsoivdntnhoutrheer',\n",
4541 " 'fahsnirpmenropenlenr',\n",
4542 " 'fahnsirpmeaoopenlirr',\n",
4543 " 'foniniapsnesolenarcr',\n",
4544 " 'fanpalfpmnrtitenaiio',\n",
4545 " 'paairovdmsoneutnnrnu',\n",
4546 " 'paafroadmsdneetnncnu',\n",
4547 " 'flaitirpnsohopernhar',\n",
4548 " 'raonnrapsroretrnaene',\n",
4549 " 'faesltopsrziuaenpeor',\n",
4550 " 'faraltopspeiuaendnor',\n",
4551 " 'fnponsopnresmseaiucn',\n",
4552 " 'fneisaapnuontmealrei',\n",
4553 " 'fatiatnpsxemneenornr',\n",
4554 " 'gaaetctjsntiasnnevel',\n",
4555 " 'faoirirpshenotenernr',\n",
4556 " 'faneoogpsrreafentpue',\n",
4557 " 'ranalrapsrfnpcrntprd',\n",
4558 " 'faoooznpshadereneesn',\n",
4559 " 'pallrhpdsnitirtnrohi',\n",
4560 " 'faodoznpssederenngsn',\n",
4561 " 'rnaovirpnmsviprannoe',\n",
4562 " 'faorrrapssnipmennnod',\n",
4563 " 'faorrrmpssnipnennnod',\n",
4564 " 'ranaaajpsrfetnrnnpni',\n",
4565 " 'panfgrddsrdjtetnncnh',\n",
4566 " 'famriaopsnnothensnri',\n",
4567 " 'fnnilrfpnsoipteacrod',\n",
4568 " 'fnstokmpnocdgnearasj',\n",
4569 " 'gaohsaojtrrlerniapln',\n",
4570 " 'raonnafptrsnctriacae',\n",
4571 " 'raonhvopterauoriutsr',\n",
4572 " 'garortajtenpufniehrr',\n",
4573 " 'raolnanptenrfhriurtp',\n",
4574 " 'raauafrptelntvrinieo',\n",
4575 " 'gaaeelsjtntttmnievth',\n",
4576 " 'falaverptinveeeioeod',\n",
4577 " 'ralnahnptirfasrionps',\n",
4578 " 'gaanrrfjtnhepdnieaer',\n",
4579 " 'raanohfptereadrinnus',\n",
4580 " 'faeiltoptnoiureirror',\n",
4581 " 'raeonftptartdsrissnc',\n",
4582 " 'gaeororjtareaanisaee',\n",
4583 " 'ranhusfptrahndritsct',\n",
4584 " 'ranhusfptrahndritsct',\n",
4585 " 'ranhusiptrahnhritsct',\n",
4586 " 'raaaskaptmfngnrinpej',\n",
4587 " 'raaieflptmostnrinhoo',\n",
4588 " 'ranhaozptrafherinspe',\n",
4589 " 'fahattmptacxuneiseor',\n",
4590 " 'faratsnptncxmseineon',\n",
4591 " 'ranaotfptsfgntricpfr',\n",
4592 " 'faroparptnerseeinuin',\n",
4593 " 'rahiknoptahgrorisijt',\n",
4594 " 'rahionoptahorerisigt',\n",
4595 " 'raalrezptsinterinonv',\n",
4596 " 'raaaotfpftmgntrpinfr',\n",
4597 " 'ghaheotjrtaroanpiseg',\n",
4598 " 'ghrosefjraozttnpfgdt',\n",
4599 " 'ghrzsorjraezrnnpfnds',\n",
4600 " 'frzltolppeiuaeednore',\n",
4601 " 'friintnppooruhedhrtr',\n",
4602 " 'frnaplkpprsrngedtnir',\n",
4603 " 'ghorreajrnaeatnphfes',\n",
4604 " 'ralizrdpfnoevorprhnv',\n",
4605 " 'ghlnavtjrnrturnprtir',\n",
4606 " 'frloknippnngsoedrhjc',\n",
4607 " 'frarilrppmnoiaednnro',\n",
4608 " 'frahiltppmaoiuednsro',\n",
4609 " 'frarilsppmnoimednnro',\n",
4610 " 'frarilsppmnoimednnro',\n",
4611 " 'frsninsppnsoamedtcri',\n",
4612 " 'ranhrhrpfratehrpnshl',\n",
4613 " 'frhonrrppaerieedsuno',\n",
4614 " 'frhrkaippangmoedsnjn',\n",
4615 " 'grtvealjeovattnerosi',\n",
4616 " 'rrejahtpernfaurepops',\n",
4617 " 'poprhredeeiaeatufose',\n",
4618 " 'pipaaoedoesmeatrfnnu',\n",
4619 " 'rraoltrpeneeapreeusi',\n",
4620 " 'foaigsrpeeofzaeunrtd',\n",
4621 " 'pftterrddxulevtcoroe',\n",
4622 " 'foafrripeesanoeunrln',\n",
4623 " 'foahroopeeaidoeunsos',\n",
4624 " 'roeaasapeatemirusinn',\n",
4625 " 'finaltnportiuhertior',\n",
4626 " 'greavlsjeatutmnesirh',\n",
4627 " 'roeotcspeadsemrusszt',\n",
4628 " 'fonsetopermgooeutnhd',\n",
4629 " 'rrevkdopeaugtrresrjo',\n",
4630 " 'grohtsojenrozonehprd',\n",
4631 " 'frlrrolpenppeeeerdru',\n",
4632 " 'filrthsponphenerrdal',\n",
4633 " 'roaasarpemfntnrunpei',\n",
4634 " 'filinrnponorpherrhtd',\n",
4635 " 'fonrharperiateeunosi',\n",
4636 " 'fomrstopeninuseusoer',\n",
4637 " 'pirnfoldonsdhetrncce',\n",
4638 " 'ronaenopeefrrorusppt',\n",
4639 " 'raajafapetnftnrniopr',\n",
4640 " 'raajaafpetnfstrniopl',\n",
4641 " 'raanntapetroosrniner',\n",
4642 " 'rlahtrupitaothroisrh',\n",
4643 " 'faahgtepetajugenisnr',\n",
4644 " 'rlahnanpitarfrroistp',\n",
4645 " 'gaahgovjetahounnislg',\n",
4646 " 'gaahgotjetahoannislg',\n",
4647 " 'rlaraezpitnsteroinnv',\n",
4648 " 'flaarimpitsnoneoinnr',\n",
4649 " 'ftashaopxtnemgeoieln',\n",
4650 " 'raaejaspnfrnemreppon',\n",
4651 " 'raaretrpefphuarnpdkr',\n",
4652 " 'farnrorpeprieaendnou',\n",
4653 " 'farnrltpephiiuendaoo',\n",
4654 " 'flrnirrpipeoneeodsrn',\n",
4655 " 'flienorpionrdaeorrns',\n",
4656 " 'farrinipneveooeeevre',\n",
4657 " 'flinhoopioradoeortss',\n",
4658 " 'plapprrdiserevtolfie',\n",
4659 " 'flahagrpisatheeolsil',\n",
4660 " 'flrhifapitaosneohsrr',\n",
4661 " 'flrsrlipitnpnoeohedr',\n",
4662 " 'gaaorocjesrnoannnans',\n",
4663 " 'flarpropispdeoeonrte',\n",
4664 " 'rlarizspisnhezronnin',\n",
4665 " 'rleerucpistpheroovdc',\n",
4666 " 'flenrrzpisaipeeooiod',\n",
4667 " 'fapjrrrpsrnehaelioee',\n",
4668 " 'frlrahoptitnenehoxes',\n",
4669 " 'raaloofpseidrtrlnosa',\n",
4670 " 'fhtfhcopexteeoelorsi',\n",
4671 " 'frlfhnhptitearehorsi',\n",
4672 " 'palfacfdsiteedtlorei',\n",
4673 " 'frhfodsptesoemehlrgg',\n",
4674 " 'prhttaedtexuisthlorh',\n",
4675 " 'rrhfaiuptetiehrhlrhr',\n",
4676 " 'rrvitaaptvhicnrhoiee',\n",
4677 " 'prviroadtvhienthoiou',\n",
4678 " 'frvgnhaptvhoeneholes',\n",
4679 " 'fhvnecrpevssanelocsl',\n",
4680 " 'phvnstidevslaotlocli',\n",
4681 " 'paahnuadesarrmtelsii',\n",
4682 " 'gaohaatjsnrtmvnlhpin',\n",
4683 " 'grlhtrojtnroprnhrprd',\n",
4684 " 'grlhtutjtnrirrnhrpei',\n",
4685 " 'rrlailvptnfeivrhrpro',\n",
4686 " 'faorphrpsnpreeelhdil',\n",
4687 " 'faoropnpsnperrelhdui',\n",
4688 " 'faormropespnnneendsn',\n",
4689 " 'rhaansrpemfrnprlnpne',\n",
4690 " 'fharnsapemprneelndne',\n",
4691 " 'rhaahanpemfatrrlnpsi',\n",
4692 " 'fharhhapemparnelndsp',\n",
4693 " 'frlrsaiptnpneoehrdee',\n",
4694 " 'rhaashlpemfnenrlnpes',\n",
4695 " 'rrlfksdptnpgmorhrejn',\n",
4696 " 'frlprosptnrpsmehridn',\n",
4697 " 'prlpisodtneonethrfre',\n",
4698 " 'frlpvdnptnrvotehrioo',\n",
4699 " 'rrliahiptnotahrhrhis',\n",
4700 " 'frlxvzaptnovdcehraoo',\n",
4701 " 'rhansaapemrnftrlnnep',\n",
4702 " 'pharesidemnfnotlnnde',\n",
4703 " 'rrlhofoptnaepdrhrsue',\n",
4704 " 'fhahiptpemaoduelnsrt',\n",
4705 " 'grlsattjtnntahnhreii',\n",
4706 " 'grlsattjtnntahnhreii',\n",
4707 " 'frneofoptrgetdehnhur',\n",
4708 " 'fhnhraiperapmoelnsdn',\n",
4709 " 'pratiahdtsxosithnohl',\n",
4710 " 'fratornptsxhprehnoed',\n",
4711 " 'rraoealptshrfnrhnepp',\n",
4712 " 'rhaaniupesmrerrlnnnr',\n",
4713 " 'fhaanaspesmrerelnnne',\n",
4714 " 'roajanfpntnsrtrhiolt',\n",
4715 " 'goanlfojntentanhirro',\n",
4716 " 'glanohnjntrrrhnritap',\n",
4717 " 'rlanoonpntrrehrritau',\n",
4718 " 'flaorevpnthtnveriexe',\n",
4719 " 'faaoranpmthtlneniexe',\n",
4720 " 'rlanuvrpntrluarritir',\n",
4721 " 'rlahaaopntafmhrrispn',\n",
4722 " 'gohrzstjnraezunhpfnd',\n",
4723 " 'glhrzssjnraezmnrpfnd',\n",
4724 " 'elkatoenngfirgerjpes',\n",
4725 " 'gohzfuvjnreshunhpnrc',\n",
4726 " 'faronnapmpohteendgan',\n",
4727 " 'forznhepsperatendnns',\n",
4728 " 'flrrpnhpnperoaerdeie',\n",
4729 " 'roaeinepnfaeonrhpsre',\n",
4730 " 'rlannzrpnfhoehrrpaen',\n",
4731 " 'fornohfpspsgltendcfc',\n",
4732 " 'glroanejnerthgnreaia',\n",
4733 " 'gothrsrjnurazenhrpfd',\n",
4734 " 'ploprhrdneeiaetrufos',\n",
4735 " 'faopohspmerdomenuiso',\n",
4736 " 'failftrpmoisuaenrorr',\n",
4737 " 'faieerlpmolsanenrosl',\n",
4738 " 'fainuorpmorldaenrnis',\n",
4739 " 'foisrropsooaeoenrrte',\n",
4740 " 'plisaafdnooaedtrrrcn',\n",
4741 " 'fahinzopmeordrenlrno',\n",
4742 " 'fahnhirpmeraopenlnsr',\n",
4743 " 'foairozpssondeennrns',\n",
4744 " 'roamrsfpssnnztrnnsnd',\n",
4745 " 'faerzlipsaheioenseno',\n",
4746 " 'faaihnzpsmoendennrla',\n",
4747 " 'faaoiropsmhonoennern',\n",
4748 " 'raarnaspsmnofzrnnnep',\n",
4749 " 'ranaaajpsrfetnrnnpni',\n",
4750 " 'pnnftsndnsdxmttaccon',\n",
4751 " 'pnnhtsndnslamttaccin',\n",
4752 " 'fnstorzpnoceheearaue',\n",
4753 " 'gaorasgjtrenmhniaeen',\n",
4754 " 'raonhvopterauoriutsr',\n",
4755 " 'garnuecjtehhtanieacv',\n",
4756 " 'faeiltoptnoiureirror',\n",
4757 " 'gaeororjtareaanisaee',\n",
4758 " 'ranhusfptrahndritsct',\n",
4759 " 'faloceeptnsaaseirnle',\n",
4760 " 'raheltaptatiuiristor',\n",
4761 " 'rahelfrptatidnristoc',\n",
4762 " 'raaalonpftmiohrpinog',\n",
4763 " 'raahnzlpftaoenrpisen',\n",
4764 " 'raahnoapftaoomrpiseg',\n",
4765 " 'raaoisrpfeeemnrpnurn',\n",
4766 " 'friintrppooruvedhrtr',\n",
4767 " 'frahiltppmaoiuednsro',\n",
4768 " 'frahiltppmaoiuednsro',\n",
4769 " 'frarilsppmnoimednnro',\n",
4770 " 'frsninsppnsoamedtcri',\n",
4771 " 'frhonrrppaerieedsuno',\n",
4772 " 'fiirohrpoeneaeerrnus',\n",
4773 " 'roalizrpefneevruprrn',\n",
4774 " 'foadzhepeloeraeueonp',\n",
4775 " 'foeaasepeatemgeusinn',\n",
4776 " 'foeaastpeatemceusinn',\n",
4777 " 'rreavespeatuhmresirk',\n",
4778 " 'fonprlsperrpnmeutidr',\n",
4779 " 'filrtovponphsverrdan',\n",
4780 " 'gaantcrjetevasnniaul',\n",
4781 " 'rlanvrapitruanroitrl',\n",
4782 " 'raarvzlpntvueireivrn',\n",
4783 " 'raanntapetroosrniner',\n",
4784 " 'gaahoaujetagernnisfe',\n",
4785 " 'rlahizlpitahenroisin',\n",
4786 " 'ftashnapxtnenmeoiela',\n",
4787 " 'rlaneznpitatehroiivn',\n",
4788 " 'raaejzfpnfrnetreppon',\n",
4789 " 'farnrlspepriimendnoo',\n",
4790 " 'flientrpionhuheorrar',\n",
4791 " 'flaahcnpistaaseolisl',\n",
4792 " 'gaavttajesvaiennloie',\n",
4793 " 'flareoepispndaeonres',\n",
4794 " 'fapjrrrpsrnehaelioee',\n",
4795 " 'rrlailvptnfeivrhrpro',\n",
4796 " 'rrlaponptnfdrtrhrpts',\n",
4797 " 'faorgropsnpjeaelhdne',\n",
4798 " 'fharroapemppnselndrh',\n",
4799 " 'rhaansrpemfrnprlnpne',\n",
4800 " 'rhaahanpemfatrrlnpsi',\n",
4801 " 'fhaphthpemdruaelntpr',\n",
4802 " 'prlhrofdtnaisdthrson',\n",
4803 " 'phahfnedemadrgtlnscn',\n",
4804 " 'paorafndesnsdstennnc',\n",
4805 " 'ransreopshnetdrlatev',\n",
4806 " 'frneofoptrgetdehnhur',\n",
4807 " 'fhnaorepenmapselaned',\n",
4808 " 'rhaaniupesmrerrlnnnr',\n",
4809 " 'rhnraudpeenmrorlsnni',\n",
4810 " 'rlanoonpntrrehrritau',\n",
4811 " 'rlanoonpntrrehrritau',\n",
4812 " 'foanpospntrrelehitiu',\n",
4813 " 'rlanuvrpntrluarritir',\n",
4814 " 'roakfrfpnfgttsrhpjuh',\n",
4815 " 'gohzfuvjnreshunhpnrc',\n",
4816 " 'gohzahfjnrenetnhpnes',\n",
4817 " 'gohzahfjnrenetnhpnes',\n",
4818 " 'forznhepsperatendnns',\n",
4819 " 'farrlnopmpacooendlee',\n",
4820 " 'farlahepmposraendsnp',\n",
4821 " 'glroanejnerthgnreaia',\n",
4822 " 'rooaeeapnefarerhupsp',\n",
4823 " 'gotnfecjnuedranhrrcp',\n",
4824 " 'flinurrpnohleherraie',\n",
4825 " 'fairoffpmonestenrnur',\n",
4826 " 'flohdzdpneaoeeeruson',\n",
4827 " 'ponfnradsndspstnaccr',\n",
4828 " 'roamrsfpssnnztrnnsnd',\n",
4829 " 'roamrsfpssnnztrnnsnd',\n",
4830 " 'faerzltpsaheixenseno',\n",
4831 " 'fartdrzpsnneedennrge',\n",
4832 " 'fartdonpsnnedsennrgs',\n",
4833 " 'fnstorzpnoceheearaue',\n",
4834 " 'raalfhspteidcmrinoch',\n",
4835 " 'gaanrfijtnheponieaee',\n",
4836 " 'fanhusiptrahnoeitsct',\n",
4837 " 'frahiltppmaoiuednsro',\n",
4838 " 'rahrnnopfaerodrpsene',\n",
4839 " 'roalizrpefneevruprrn',\n",
4840 " 'foailsopeeoezoeunrsd',\n",
4841 " 'roeavtspeatusmrusirz',\n",
4842 " 'grohosujenrrzhnehpad',\n",
4843 " 'frlrrolpenppeeeerdru',\n",
4844 " 'rooasahpenflmeruhpln',\n",
4845 " 'gaanhfejnterttneirpr',\n",
4846 " 'raajafapetnftnrniopr',\n",
4847 " 'raarvzlpntvueireivrn',\n",
4848 " 'gartptfjnerdxtneevto',\n",
4849 " 'flientrpionhuheorrar',\n",
4850 " 'flareoepispndaeonres',\n",
4851 " 'fharohepempnlaelndhc',\n",
4852 " 'paneoafdshgeedtlahun',\n",
4853 " 'rlanoonpntrrehrritau',\n",
4854 " 'raarcvapmfpevsrnpdho',\n",
4855 " 'rlarnerpnfarrprrplie',\n",
4856 " 'flinurrpnohleherraie',\n",
4857 " 'fahoroopmeannoenlenh',\n",
4858 " 'raallrmpftnianrpirol',\n",
4859 " 'rlanvrapitruanroitrl',\n",
4860 " 'faonpfcpeeedtaenuatr',\n",
4861 " 'raallrmpftnianrpirol']"
4864 "execution_count": 44,
4866 "output_type": "execute_result"
4870 "[cadenus_decipher(first_chunk, w, keycolumn)[:20] for w in hinted_keywords]"
4874 "cell_type": "code",
4875 "execution_count": 45,
4884 "execution_count": 45,
4886 "output_type": "execute_result"
4890 "[w for w in hinted_keywords if cadenus_decipher(first_chunk, w, keycolumn).startswith('phaseseven')]"
4894 "cell_type": "code",
4895 "execution_count": 46,
4899 "# def cadenus_break_worker(message, keyword, keycolumn, fitness):\n",
4900 "# message_chunks = chunks(message, 175)\n",
4901 "# plaintext = ''.join(cadenus_decipher(c, keyword, keycolumn) for c in message_chunks)\n",
4902 "# fit = fitness(plaintext)\n",
4903 "# return (keyword, keycolumn), fit"
4907 "cell_type": "code",
4908 "execution_count": 47,
4912 "# def cadenus_break(message, words=keywords, fitness=Pbigrams):\n",
4913 "# c = make_cadenus_keycolumn(reverse=True)\n",
4914 "# results = starmap(cadenus_break_worker, [(message, \n",
4916 "# make_cadenus_keycolumn(doubled_letters='vw', start=s, reverse=r), \n",
4918 "# for w in words for s in string.ascii_lowercase for r in [True, False]])\n",
4919 "# # return list(results)\n",
4920 "# return max(results, key=lambda k: k[1])"
4924 "cell_type": "code",
4925 "execution_count": 48,
4958 " -5436.133070290792)"
4961 "execution_count": 48,
4963 "output_type": "execute_result"
4967 "key8b, fitness = cadenus_break(c8bl, words=hinted_keywords, fitness=Ptrigrams)\n",
4972 "cell_type": "code",
4973 "execution_count": 49,
4977 "ename": "IndexError",
4978 "evalue": "string index out of range",
4979 "output_type": "error",
4981 "\u001b[0;31m---------------------------------------------------------------------------\u001b[0m",
4982 "\u001b[0;31mRemoteTraceback\u001b[0m Traceback (most recent call last)",
4983 "\u001b[0;31mRemoteTraceback\u001b[0m: \n\"\"\"\nTraceback (most recent call last):\n File \"/usr/lib/python3.6/multiprocessing/pool.py\", line 119, in worker\n result = (True, func(*args, **kwds))\n File \"/usr/lib/python3.6/multiprocessing/pool.py\", line 47, in starmapstar\n return list(itertools.starmap(args[0], args[1]))\n File \"/home/neil/Documents/programming/national-cipher-challenge/cipher/cadenus.py\", line 120, in cadenus_break_worker\n plaintext = ''.join(cadenus_decipher(c, keyword, keycolumn) for c in message_chunks)\n File \"/home/neil/Documents/programming/national-cipher-challenge/cipher/cadenus.py\", line 120, in <genexpr>\n plaintext = ''.join(cadenus_decipher(c, keyword, keycolumn) for c in message_chunks)\n File \"/home/neil/Documents/programming/national-cipher-challenge/cipher/cadenus.py\", line 89, in cadenus_decipher\n untransposed_rows = [untranspose(r, transpositions) for r in rows]\n File \"/home/neil/Documents/programming/national-cipher-challenge/cipher/cadenus.py\", line 89, in <listcomp>\n untransposed_rows = [untranspose(r, transpositions) for r in rows]\n File \"/home/neil/Documents/programming/national-cipher-challenge/support/utilities.py\", line 101, in untranspose\n transposed[t] = items[p]\nIndexError: string index out of range\n\"\"\"",
4984 "\nThe above exception was the direct cause of the following exception:\n",
4985 "\u001b[0;31mIndexError\u001b[0m Traceback (most recent call last)",
4986 "\u001b[0;32m<ipython-input-49-ef8b0c9b9c63>\u001b[0m in \u001b[0;36m<module>\u001b[0;34m()\u001b[0m\n\u001b[0;32m----> 1\u001b[0;31m \u001b[0mkey8b\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mfitness\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mcadenus_break\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mc8bl\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mfitness\u001b[0m\u001b[0;34m=\u001b[0m\u001b[0mPtrigrams\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m 2\u001b[0m \u001b[0mkey8b\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mfitness\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n",
4987 "\u001b[0;32m~/Documents/programming/national-cipher-challenge/cipher/cadenus.py\u001b[0m in \u001b[0;36mcadenus_break\u001b[0;34m(message, words, doubled_letters, fitness)\u001b[0m\n\u001b[1;32m 106\u001b[0m start=s, reverse=r), \n\u001b[1;32m 107\u001b[0m fitness)\n\u001b[0;32m--> 108\u001b[0;31m \u001b[0;32mfor\u001b[0m \u001b[0mw\u001b[0m \u001b[0;32min\u001b[0m \u001b[0mwords\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m 109\u001b[0m \u001b[0;32mfor\u001b[0m \u001b[0ms\u001b[0m \u001b[0;32min\u001b[0m \u001b[0mstring\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mascii_lowercase\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 110\u001b[0m \u001b[0;32mfor\u001b[0m \u001b[0mr\u001b[0m \u001b[0;32min\u001b[0m \u001b[0;34m[\u001b[0m\u001b[0;32mTrue\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0;32mFalse\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n",
4988 "\u001b[0;32m/usr/lib/python3.6/multiprocessing/pool.py\u001b[0m in \u001b[0;36mstarmap\u001b[0;34m(self, func, iterable, chunksize)\u001b[0m\n\u001b[1;32m 272\u001b[0m \u001b[0;31m`\u001b[0m\u001b[0mfunc\u001b[0m\u001b[0;31m`\u001b[0m \u001b[0;32mand\u001b[0m \u001b[0;34m(\u001b[0m\u001b[0ma\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mb\u001b[0m\u001b[0;34m)\u001b[0m \u001b[0mbecomes\u001b[0m \u001b[0mfunc\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0ma\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mb\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 273\u001b[0m '''\n\u001b[0;32m--> 274\u001b[0;31m \u001b[0;32mreturn\u001b[0m \u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0m_map_async\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mfunc\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0miterable\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mstarmapstar\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mchunksize\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mget\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m 275\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 276\u001b[0m def starmap_async(self, func, iterable, chunksize=None, callback=None,\n",
4989 "\u001b[0;32m/usr/lib/python3.6/multiprocessing/pool.py\u001b[0m in \u001b[0;36mget\u001b[0;34m(self, timeout)\u001b[0m\n\u001b[1;32m 642\u001b[0m \u001b[0;32mreturn\u001b[0m \u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0m_value\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 643\u001b[0m \u001b[0;32melse\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m--> 644\u001b[0;31m \u001b[0;32mraise\u001b[0m \u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0m_value\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m 645\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 646\u001b[0m \u001b[0;32mdef\u001b[0m \u001b[0m_set\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mself\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mi\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mobj\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n",
4990 "\u001b[0;31mIndexError\u001b[0m: string index out of range"
4995 "key8b, fitness = cadenus_break(c8bl, fitness=Ptrigrams)\n",
5000 "cell_type": "code",
5001 "execution_count": null,
5005 "cadenus_decipher(first_chunk, key8b[0], key8b[1])"
5009 "cell_type": "code",
5010 "execution_count": null,
5014 "[(w, s, d1+d2, r)\n",
5015 " for w in hinted_keywords \n",
5016 " for d1 in string.ascii_lowercase[:25]\n",
5017 " for d2 in string.ascii_lowercase\n",
5018 " for s in string.ascii_lowercase \n",
5019 " for r in [True, False]\n",
5021 " if cadenus_decipher(first_chunk, w, \n",
5022 " make_cadenus_keycolumn(doubled_letters=d1+d2, start=s, reverse=r)).startswith('finalreport')]"
5026 "cell_type": "code",
5027 "execution_count": null,
5031 "[(w, s, d1+d2, r, cadenus_decipher(first_chunk, w, \n",
5032 " make_cadenus_keycolumn(doubled_letters=d1+d2, start=s, reverse=r))[:50])\n",
5033 " for w in hinted_keywords \n",
5034 " for d1 in string.ascii_lowercase[:25]\n",
5035 " for d2 in string.ascii_lowercase\n",
5036 " for s in string.ascii_lowercase \n",
5037 " for r in [True, False]\n",
5039 " if cadenus_decipher(first_chunk, w, \n",
5040 " make_cadenus_keycolumn(doubled_letters=d1+d2, start=s, reverse=r)).startswith('finalreport')]"
5044 "cell_type": "code",
5045 "execution_count": null,
5051 "[(w, s, d1+chr(ord(d1)+1), r)\n",
5052 " for w in hinted_keywords \n",
5053 " for d1 in string.ascii_lowercase[:25]\n",
5054 " # for d2 in string.ascii_lowercase\n",
5055 " for s in string.ascii_lowercase \n",
5056 " for r in [True, False]\n",
5058 " if cadenus_decipher(first_chunk, w, make_cadenus_keycolumn(doubled_letters=d1+chr(ord(d1)+1), start=s, reverse=r)).startswith('final')]"
5062 "cell_type": "code",
5063 "execution_count": null,
5067 "cadenus_decipher(first_chunk, 'filbert', make_cadenus_keycolumn(doubled_letters='lu', start='m', reverse=False))"
5071 "cell_type": "code",
5072 "execution_count": null,
5076 "chunks(first_chunk, 175)"
5080 "cell_type": "code",
5081 "execution_count": null,
5089 "display_name": "Python 3",
5090 "language": "python",
5094 "codemirror_mode": {
5098 "file_extension": ".py",
5099 "mimetype": "text/x-python",
5101 "nbconvert_exporter": "python",
5102 "pygments_lexer": "ipython3",