about summary refs log tree commit diff
diff options
context:
space:
mode:
authorLeah Neukirchen <leah@vuxu.org>2017-12-13 16:10:20 +0100
committerLeah Neukirchen <leah@vuxu.org>2017-12-13 16:10:20 +0100
commit777766e6cf7b8c9851b4015e9691a038d3b5808b (patch)
tree8273ccc84f739463325fc0a33b1a64213834c8cf
parent7ebb9a12f811f9b334815276621a2bdef391e917 (diff)
downloadadventofcode2017-777766e6cf7b8c9851b4015e9691a038d3b5808b.tar.gz
adventofcode2017-777766e6cf7b8c9851b4015e9691a038d3b5808b.tar.xz
adventofcode2017-777766e6cf7b8c9851b4015e9691a038d3b5808b.zip
day12
-rw-r--r--day122000
-rw-r--r--day12.cc91
-rw-r--r--day12.k8
3 files changed, 2099 insertions, 0 deletions
diff --git a/day12 b/day12
new file mode 100644
index 0000000..af28e28
--- /dev/null
+++ b/day12
@@ -0,0 +1,2000 @@
+0 <-> 889, 1229, 1736
+1 <-> 1, 480, 793, 1361
+2 <-> 607
+3 <-> 273, 422
+4 <-> 965, 1052, 1130, 1591
+5 <-> 1998
+6 <-> 483, 1628
+7 <-> 1012, 1242, 1244, 1491
+8 <-> 524
+9 <-> 13, 281, 1498
+10 <-> 10
+11 <-> 1956
+12 <-> 598, 621, 1210
+13 <-> 9
+14 <-> 1728
+15 <-> 912, 1461
+16 <-> 1489, 1680, 1994
+17 <-> 854
+18 <-> 1157, 1299
+19 <-> 759
+20 <-> 1352, 1831
+21 <-> 1425
+22 <-> 470, 685, 857, 1526
+23 <-> 405
+24 <-> 43, 536, 1849
+25 <-> 1674
+26 <-> 26, 1738
+27 <-> 558
+28 <-> 1863
+29 <-> 154, 649, 1818
+30 <-> 721, 1366
+31 <-> 725
+32 <-> 413, 880, 903
+33 <-> 414, 442, 1403
+34 <-> 489, 1308
+35 <-> 385, 1254, 1464
+36 <-> 167, 1013, 1860
+37 <-> 535
+38 <-> 605, 1297
+39 <-> 680, 1408, 1982
+40 <-> 169, 615, 952, 1547
+41 <-> 644, 991, 1319, 1509
+42 <-> 453, 1315
+43 <-> 24, 200, 805
+44 <-> 919, 1083
+45 <-> 500
+46 <-> 1532, 1550
+47 <-> 910, 1837
+48 <-> 1849
+49 <-> 542, 1945
+50 <-> 57, 660
+51 <-> 354, 934
+52 <-> 1212
+53 <-> 569
+54 <-> 706
+55 <-> 55, 114, 1077
+56 <-> 1453
+57 <-> 50, 1438
+58 <-> 616, 738
+59 <-> 1242
+60 <-> 312, 523, 648
+61 <-> 748, 1780, 1965
+62 <-> 1533, 1909
+63 <-> 562, 661, 1016
+64 <-> 280, 300, 677
+65 <-> 661, 698, 1881
+66 <-> 283, 440
+67 <-> 382, 421
+68 <-> 986, 1592, 1824
+69 <-> 541, 1363
+70 <-> 266, 1855
+71 <-> 371, 433, 1055, 1682
+72 <-> 793
+73 <-> 73
+74 <-> 1139
+75 <-> 770, 1190, 1409, 1433, 1886
+76 <-> 1135
+77 <-> 492, 1771
+78 <-> 575, 1107, 1596, 1670
+79 <-> 1374
+80 <-> 1168, 1519
+81 <-> 1258
+82 <-> 919, 1519, 1768
+83 <-> 1463
+84 <-> 684
+85 <-> 517, 1655
+86 <-> 1226
+87 <-> 1700
+88 <-> 523, 1292, 1939
+89 <-> 177, 1695, 1706
+90 <-> 400, 1683
+91 <-> 194
+92 <-> 106, 1546
+93 <-> 104
+94 <-> 501, 1686
+95 <-> 285, 1985
+96 <-> 402, 770
+97 <-> 196
+98 <-> 318, 1827
+99 <-> 220, 1272, 1766, 1802
+100 <-> 1105
+101 <-> 380, 957
+102 <-> 1305, 1483
+103 <-> 262, 481, 621
+104 <-> 93, 708, 1731
+105 <-> 282
+106 <-> 92, 901
+107 <-> 553, 742, 1833
+108 <-> 480, 1140
+109 <-> 1247
+110 <-> 1549
+111 <-> 1283
+112 <-> 1503, 1963
+113 <-> 819, 1601
+114 <-> 55, 593, 1020
+115 <-> 324
+116 <-> 378
+117 <-> 1534
+118 <-> 1740, 1836
+119 <-> 1223, 1283
+120 <-> 435, 1063
+121 <-> 404, 939
+122 <-> 294, 360, 1809
+123 <-> 1166
+124 <-> 1988
+125 <-> 163
+126 <-> 126
+127 <-> 255, 754
+128 <-> 634, 969
+129 <-> 563, 1732, 1926
+130 <-> 1196
+131 <-> 1019, 1429
+132 <-> 1287, 1417
+133 <-> 1453
+134 <-> 184, 786
+135 <-> 647
+136 <-> 260, 306
+137 <-> 1342
+138 <-> 292
+139 <-> 1265
+140 <-> 613
+141 <-> 1001, 1217
+142 <-> 142, 1901
+143 <-> 758, 822, 1533
+144 <-> 866, 930, 1197, 1443, 1665
+145 <-> 1672
+146 <-> 1937
+147 <-> 1409, 1697
+148 <-> 608, 954, 1624
+149 <-> 527, 652, 1938
+150 <-> 709
+151 <-> 447, 1305, 1314
+152 <-> 1741
+153 <-> 901, 1997
+154 <-> 29, 929
+155 <-> 1178, 1976
+156 <-> 560
+157 <-> 522
+158 <-> 541
+159 <-> 1212, 1878
+160 <-> 1078
+161 <-> 1128, 1913
+162 <-> 588, 734
+163 <-> 125, 1073, 1952
+164 <-> 1156
+165 <-> 1781
+166 <-> 1692
+167 <-> 36, 1637
+168 <-> 1043, 1085
+169 <-> 40, 334, 1257, 1313
+170 <-> 170
+171 <-> 171
+172 <-> 1391
+173 <-> 925
+174 <-> 1733
+175 <-> 175, 1466
+176 <-> 726, 1182
+177 <-> 89, 1100
+178 <-> 611, 1141
+179 <-> 1036, 1307
+180 <-> 1556
+181 <-> 1930
+182 <-> 775, 1284
+183 <-> 1907
+184 <-> 134, 1981
+185 <-> 255, 1278
+186 <-> 1891
+187 <-> 531, 1318
+188 <-> 790, 1623
+189 <-> 379, 1749, 1865
+190 <-> 1103, 1676
+191 <-> 534
+192 <-> 477
+193 <-> 193, 860
+194 <-> 91, 710, 1780
+195 <-> 290, 1383, 1510
+196 <-> 97, 1664
+197 <-> 1416
+198 <-> 287, 1760
+199 <-> 366
+200 <-> 43
+201 <-> 813, 1882
+202 <-> 246, 1175
+203 <-> 203, 1007
+204 <-> 204, 923
+205 <-> 924
+206 <-> 1162, 1818
+207 <-> 365, 487, 923
+208 <-> 1281, 1290
+209 <-> 1280
+210 <-> 210, 288, 1333
+211 <-> 211, 417, 754
+212 <-> 1698
+213 <-> 1626
+214 <-> 1256
+215 <-> 215, 1385, 1671
+216 <-> 811, 1025
+217 <-> 554, 1715
+218 <-> 1483
+219 <-> 1741
+220 <-> 99, 530, 1081, 1319, 1801
+221 <-> 804, 1144
+222 <-> 1288, 1702
+223 <-> 223, 1231
+224 <-> 649, 1179
+225 <-> 1271, 1776
+226 <-> 226, 1991
+227 <-> 496, 857, 1004, 1821
+228 <-> 371, 500
+229 <-> 1162
+230 <-> 693, 1081
+231 <-> 506, 973
+232 <-> 859, 969, 1922
+233 <-> 233
+234 <-> 875, 1006
+235 <-> 1035, 1998
+236 <-> 236
+237 <-> 289, 569, 1440
+238 <-> 1249, 1923
+239 <-> 1564, 1775, 1944
+240 <-> 1888
+241 <-> 951, 1874
+242 <-> 825
+243 <-> 384, 983, 1838
+244 <-> 715, 1501
+245 <-> 592, 671
+246 <-> 202, 391, 632, 656
+247 <-> 663
+248 <-> 253, 752
+249 <-> 1073, 1558
+250 <-> 290
+251 <-> 792, 1389
+252 <-> 797
+253 <-> 248, 771
+254 <-> 254, 1047
+255 <-> 127, 185, 369
+256 <-> 623
+257 <-> 1636, 1740
+258 <-> 317
+259 <-> 1775
+260 <-> 136, 561, 1290
+261 <-> 359, 1657
+262 <-> 103, 697, 1074
+263 <-> 1205
+264 <-> 1779, 1782
+265 <-> 1407
+266 <-> 70, 1215, 1306
+267 <-> 333, 790
+268 <-> 603
+269 <-> 269, 1497
+270 <-> 270, 1613
+271 <-> 1416, 1562, 1923
+272 <-> 579, 894
+273 <-> 3, 993
+274 <-> 333
+275 <-> 1188
+276 <-> 535, 645, 1166, 1269
+277 <-> 1369
+278 <-> 744, 1717
+279 <-> 349, 695, 985, 1096
+280 <-> 64, 1516
+281 <-> 9, 427, 768, 1468
+282 <-> 105, 867
+283 <-> 66, 1235, 1525, 1748
+284 <-> 530
+285 <-> 95, 800, 1191
+286 <-> 339, 611, 1581
+287 <-> 198, 1285, 1501
+288 <-> 210, 1059
+289 <-> 237, 1928
+290 <-> 195, 250, 1934
+291 <-> 337, 1902
+292 <-> 138, 1805, 1849
+293 <-> 906
+294 <-> 122, 1582
+295 <-> 602
+296 <-> 778
+297 <-> 471, 483
+298 <-> 298
+299 <-> 402, 729
+300 <-> 64, 1002
+301 <-> 856
+302 <-> 1084, 1538, 1739
+303 <-> 892, 1774
+304 <-> 1029, 1350
+305 <-> 521, 1628, 1902
+306 <-> 136, 469, 653, 835
+307 <-> 981
+308 <-> 1997
+309 <-> 1612
+310 <-> 1338, 1571
+311 <-> 1388
+312 <-> 60
+313 <-> 1557
+314 <-> 886, 1704
+315 <-> 672, 779
+316 <-> 1062, 1906
+317 <-> 258, 1290
+318 <-> 98, 318
+319 <-> 1974
+320 <-> 839
+321 <-> 395, 615, 909, 1046
+322 <-> 1077, 1390, 1989
+323 <-> 323, 773, 1571
+324 <-> 115, 493, 511, 650
+325 <-> 325
+326 <-> 1944, 1972
+327 <-> 1489
+328 <-> 412, 468
+329 <-> 1637
+330 <-> 556, 1176
+331 <-> 656
+332 <-> 564, 1688
+333 <-> 267, 274, 421, 1205, 1743
+334 <-> 169, 1896
+335 <-> 1176
+336 <-> 638, 1408, 1633
+337 <-> 291, 844, 1549
+338 <-> 515
+339 <-> 286
+340 <-> 340, 1959
+341 <-> 943
+342 <-> 417, 638, 1116, 1536
+343 <-> 1030
+344 <-> 584, 1751
+345 <-> 345, 1810
+346 <-> 346
+347 <-> 587
+348 <-> 515, 1187
+349 <-> 279, 349
+350 <-> 1749
+351 <-> 1030, 1097
+352 <-> 352
+353 <-> 353, 683
+354 <-> 51, 354, 735
+355 <-> 1362
+356 <-> 1593
+357 <-> 357
+358 <-> 441, 501, 899, 1672
+359 <-> 261
+360 <-> 122, 360, 1234, 1927
+361 <-> 736
+362 <-> 1169
+363 <-> 780
+364 <-> 444, 905, 1049, 1911
+365 <-> 207
+366 <-> 199, 1469
+367 <-> 1612
+368 <-> 675, 1800
+369 <-> 255
+370 <-> 370, 873, 962, 1238
+371 <-> 71, 228, 456
+372 <-> 1912
+373 <-> 1318
+374 <-> 1018, 1246
+375 <-> 898, 1303
+376 <-> 376, 573
+377 <-> 1080
+378 <-> 116, 1140
+379 <-> 189, 1984
+380 <-> 101
+381 <-> 472, 827, 1097
+382 <-> 67
+383 <-> 383, 582
+384 <-> 243, 432, 444, 569, 634
+385 <-> 35
+386 <-> 1496
+387 <-> 637, 737, 756, 1293
+388 <-> 1562
+389 <-> 633
+390 <-> 488
+391 <-> 246, 853, 1422
+392 <-> 1253, 1331
+393 <-> 921, 1567, 1777, 1970
+394 <-> 809
+395 <-> 321, 798, 1040
+396 <-> 746, 1332
+397 <-> 400, 953
+398 <-> 1958
+399 <-> 399
+400 <-> 90, 397, 808, 1485
+401 <-> 1395
+402 <-> 96, 299, 1388
+403 <-> 716
+404 <-> 121
+405 <-> 23, 934, 1221
+406 <-> 1007
+407 <-> 1391
+408 <-> 497, 1090, 1644
+409 <-> 1479
+410 <-> 793, 1977
+411 <-> 1026
+412 <-> 328, 581, 806
+413 <-> 32, 1354
+414 <-> 33, 1920
+415 <-> 799, 1207, 1880
+416 <-> 1862
+417 <-> 211, 342, 589, 1858
+418 <-> 556, 1437, 1490
+419 <-> 1393
+420 <-> 420
+421 <-> 67, 333, 1813
+422 <-> 3, 706, 1598, 1721
+423 <-> 1834
+424 <-> 854, 1442
+425 <-> 855, 1080
+426 <-> 1408, 1469
+427 <-> 281
+428 <-> 832, 1998
+429 <-> 553, 657, 834
+430 <-> 1466
+431 <-> 1357
+432 <-> 384
+433 <-> 71
+434 <-> 434, 489, 1137
+435 <-> 120
+436 <-> 972, 1461
+437 <-> 550
+438 <-> 486, 844
+439 <-> 978
+440 <-> 66, 705, 1850
+441 <-> 358, 589, 783, 804, 1129
+442 <-> 33, 497
+443 <-> 1806
+444 <-> 364, 384, 1698
+445 <-> 1208, 1294, 1452
+446 <-> 1143, 1452
+447 <-> 151, 1072
+448 <-> 448
+449 <-> 997, 1829
+450 <-> 1277
+451 <-> 1531, 1866
+452 <-> 1175, 1622, 1975
+453 <-> 42, 1486
+454 <-> 689
+455 <-> 1497
+456 <-> 371, 1577
+457 <-> 702
+458 <-> 461, 921, 1279
+459 <-> 1004
+460 <-> 485, 505, 1211, 1451
+461 <-> 458, 541, 916, 1844
+462 <-> 1281
+463 <-> 856, 1481
+464 <-> 602, 1476, 1553
+465 <-> 543, 1566
+466 <-> 847, 1593
+467 <-> 1270
+468 <-> 328, 829
+469 <-> 306, 667, 720, 1931
+470 <-> 22
+471 <-> 297
+472 <-> 381
+473 <-> 473
+474 <-> 599, 1146
+475 <-> 1570, 1894
+476 <-> 1145
+477 <-> 192, 1193, 1690
+478 <-> 1469, 1840
+479 <-> 1684
+480 <-> 1, 108
+481 <-> 103, 963
+482 <-> 1778
+483 <-> 6, 297, 1662
+484 <-> 1435
+485 <-> 460
+486 <-> 438
+487 <-> 207, 998, 1185
+488 <-> 390, 1231, 1668
+489 <-> 34, 434, 1341
+490 <-> 990, 1203
+491 <-> 936
+492 <-> 77
+493 <-> 324
+494 <-> 1984
+495 <-> 495, 1954
+496 <-> 227
+497 <-> 408, 442, 1551
+498 <-> 1704, 1788
+499 <-> 836
+500 <-> 45, 228, 1358, 1798
+501 <-> 94, 358, 1559
+502 <-> 951
+503 <-> 1036
+504 <-> 1303
+505 <-> 460
+506 <-> 231, 606, 1473
+507 <-> 1109
+508 <-> 1724
+509 <-> 1644
+510 <-> 848
+511 <-> 324, 1036
+512 <-> 523
+513 <-> 809, 1294
+514 <-> 785
+515 <-> 338, 348, 1027, 1193, 1226
+516 <-> 1988
+517 <-> 85, 1482
+518 <-> 518
+519 <-> 1625
+520 <-> 520
+521 <-> 305, 1033
+522 <-> 157, 1355, 1476, 1588
+523 <-> 60, 88, 512
+524 <-> 8, 1998
+525 <-> 990, 1275
+526 <-> 1310, 1552
+527 <-> 149, 979, 1805
+528 <-> 698
+529 <-> 631, 970
+530 <-> 220, 284, 1533, 1944
+531 <-> 187, 551, 1168, 1574
+532 <-> 1484
+533 <-> 892
+534 <-> 191, 879
+535 <-> 37, 276, 1527
+536 <-> 24, 1094
+537 <-> 747, 952
+538 <-> 1620, 1735
+539 <-> 858, 1467
+540 <-> 1263, 1572
+541 <-> 69, 158, 461
+542 <-> 49, 1384
+543 <-> 465, 639, 873
+544 <-> 1338
+545 <-> 1967
+546 <-> 806, 1239
+547 <-> 792, 1039, 1078
+548 <-> 548, 1891, 1941
+549 <-> 861
+550 <-> 437, 1209, 1967
+551 <-> 531, 888, 896
+552 <-> 798
+553 <-> 107, 429, 1330, 1951
+554 <-> 217
+555 <-> 744, 947, 1246
+556 <-> 330, 418, 1070, 1925
+557 <-> 1826, 1854
+558 <-> 27, 1629
+559 <-> 1042, 1150
+560 <-> 156, 1472, 1834
+561 <-> 260
+562 <-> 63
+563 <-> 129, 1309
+564 <-> 332
+565 <-> 1770, 1842
+566 <-> 621
+567 <-> 1160, 1178, 1642
+568 <-> 895
+569 <-> 53, 237, 384
+570 <-> 641
+571 <-> 571, 1261, 1924
+572 <-> 882
+573 <-> 376
+574 <-> 982
+575 <-> 78, 1255
+576 <-> 887, 1539
+577 <-> 603, 1122, 1679
+578 <-> 742
+579 <-> 272, 1444, 1747
+580 <-> 797, 1554, 1718
+581 <-> 412, 1926
+582 <-> 383
+583 <-> 1611
+584 <-> 344, 1620
+585 <-> 1692
+586 <-> 1383
+587 <-> 347, 1351
+588 <-> 162, 1220
+589 <-> 417, 441
+590 <-> 1919
+591 <-> 884, 992
+592 <-> 245, 814
+593 <-> 114
+594 <-> 1843
+595 <-> 1809
+596 <-> 837
+597 <-> 1563, 1575
+598 <-> 12, 605, 984
+599 <-> 474, 1218
+600 <-> 732, 1237, 1714
+601 <-> 1913
+602 <-> 295, 464, 1061
+603 <-> 268, 577, 720
+604 <-> 604
+605 <-> 38, 598
+606 <-> 506, 686, 1813
+607 <-> 2, 1948
+608 <-> 148
+609 <-> 1571
+610 <-> 772, 901
+611 <-> 178, 286, 880
+612 <-> 1814
+613 <-> 140, 883, 1198, 1764, 1942
+614 <-> 1352
+615 <-> 40, 321
+616 <-> 58, 1413
+617 <-> 624, 1008, 1591, 1791
+618 <-> 1625
+619 <-> 871, 1567
+620 <-> 1954
+621 <-> 12, 103, 566
+622 <-> 1895
+623 <-> 256, 1767
+624 <-> 617
+625 <-> 663
+626 <-> 626
+627 <-> 1650
+628 <-> 884
+629 <-> 1104, 1421
+630 <-> 630, 864
+631 <-> 529, 646
+632 <-> 246
+633 <-> 389, 1847
+634 <-> 128, 384
+635 <-> 1553, 1817
+636 <-> 636
+637 <-> 387
+638 <-> 336, 342, 646, 1453
+639 <-> 543, 815, 1087
+640 <-> 1422, 1597
+641 <-> 570, 805, 993, 1961
+642 <-> 1371
+643 <-> 959, 1044, 1444
+644 <-> 41
+645 <-> 276, 1022, 1184
+646 <-> 631, 638, 1790
+647 <-> 135, 1286
+648 <-> 60
+649 <-> 29, 224, 1636
+650 <-> 324
+651 <-> 863, 1321
+652 <-> 149, 687, 1128, 1346
+653 <-> 306
+654 <-> 1409
+655 <-> 1142, 1733
+656 <-> 246, 331, 768, 1815
+657 <-> 429
+658 <-> 1511, 1569
+659 <-> 1744
+660 <-> 50, 796, 1524
+661 <-> 63, 65, 810
+662 <-> 995, 1661
+663 <-> 247, 625, 1001
+664 <-> 664
+665 <-> 1305
+666 <-> 666, 1817
+667 <-> 469, 1003, 1550
+668 <-> 1540, 1958
+669 <-> 831, 883, 1349, 1719
+670 <-> 1531
+671 <-> 245, 671, 1693
+672 <-> 315, 1088
+673 <-> 942, 1381, 1660
+674 <-> 880
+675 <-> 368
+676 <-> 1269, 1699
+677 <-> 64, 1654
+678 <-> 784
+679 <-> 1760
+680 <-> 39
+681 <-> 681
+682 <-> 728, 749, 1995
+683 <-> 353
+684 <-> 84, 1150
+685 <-> 22
+686 <-> 606
+687 <-> 652, 1687
+688 <-> 1878
+689 <-> 454, 689
+690 <-> 924, 1183
+691 <-> 1410, 1413
+692 <-> 1702
+693 <-> 230, 1658
+694 <-> 820, 1282, 1873
+695 <-> 279
+696 <-> 1168
+697 <-> 262, 766, 776
+698 <-> 65, 528, 698, 940
+699 <-> 1778
+700 <-> 743, 1459, 1825
+701 <-> 1475
+702 <-> 457, 792, 861, 1467
+703 <-> 1581
+704 <-> 1969
+705 <-> 440, 1145
+706 <-> 54, 422
+707 <-> 1015, 1780
+708 <-> 104, 1266
+709 <-> 150, 1778
+710 <-> 194
+711 <-> 751
+712 <-> 963
+713 <-> 1525, 1762
+714 <-> 1713
+715 <-> 244, 1293, 1421
+716 <-> 403, 1572
+717 <-> 1142
+718 <-> 1204
+719 <-> 1672
+720 <-> 469, 603
+721 <-> 30, 1268, 1400
+722 <-> 1183
+723 <-> 1012
+724 <-> 1029, 1289, 1368
+725 <-> 31, 1039
+726 <-> 176, 726
+727 <-> 856
+728 <-> 682, 1000
+729 <-> 299, 1216, 1967
+730 <-> 850, 900
+731 <-> 1540, 1884
+732 <-> 600, 784
+733 <-> 1655
+734 <-> 162
+735 <-> 354, 1955
+736 <-> 361, 1084, 1822
+737 <-> 387
+738 <-> 58, 1573
+739 <-> 1119, 1216, 1822
+740 <-> 829, 1219
+741 <-> 1164
+742 <-> 107, 578
+743 <-> 700, 1744
+744 <-> 278, 555
+745 <-> 835, 1903
+746 <-> 396
+747 <-> 537, 1843
+748 <-> 61
+749 <-> 682, 1217, 1731
+750 <-> 874, 1110, 1724
+751 <-> 711, 1767
+752 <-> 248, 1011
+753 <-> 1327, 1885
+754 <-> 127, 211, 1117
+755 <-> 755
+756 <-> 387
+757 <-> 1098, 1169
+758 <-> 143, 1689
+759 <-> 19, 1517
+760 <-> 831, 1915
+761 <-> 761, 1195
+762 <-> 1634
+763 <-> 763
+764 <-> 848, 1375
+765 <-> 765, 1136
+766 <-> 697, 1295, 1887
+767 <-> 1906
+768 <-> 281, 656, 1031
+769 <-> 1457, 1863
+770 <-> 75, 96
+771 <-> 253, 846, 1375
+772 <-> 610
+773 <-> 323
+774 <-> 1067
+775 <-> 182, 1494
+776 <-> 697
+777 <-> 1136
+778 <-> 296, 1057
+779 <-> 315, 1631, 1796
+780 <-> 363, 780, 1814
+781 <-> 928, 1423
+782 <-> 1850
+783 <-> 441
+784 <-> 678, 732, 999, 1988
+785 <-> 514, 1248
+786 <-> 134, 786, 1009
+787 <-> 1348, 1863
+788 <-> 891, 1183, 1455
+789 <-> 1310, 1420, 1510
+790 <-> 188, 267
+791 <-> 1276
+792 <-> 251, 547, 702
+793 <-> 1, 72, 410, 1092
+794 <-> 880
+795 <-> 1799, 1807
+796 <-> 660, 1548
+797 <-> 252, 580, 797
+798 <-> 395, 552
+799 <-> 415, 799
+800 <-> 285, 1889
+801 <-> 801
+802 <-> 802
+803 <-> 1188, 1326, 1935
+804 <-> 221, 441
+805 <-> 43, 641, 1772
+806 <-> 412, 546, 918, 1617
+807 <-> 876, 1887
+808 <-> 400, 1435, 1716
+809 <-> 394, 513
+810 <-> 661
+811 <-> 216, 1259
+812 <-> 1883
+813 <-> 201, 1692
+814 <-> 592
+815 <-> 639
+816 <-> 1041, 1734
+817 <-> 1134, 1432
+818 <-> 1575
+819 <-> 113, 1063
+820 <-> 694
+821 <-> 1242
+822 <-> 143, 892
+823 <-> 1393, 1492
+824 <-> 946
+825 <-> 242, 999
+826 <-> 1594
+827 <-> 381, 1079, 1580
+828 <-> 1941
+829 <-> 468, 740, 1905
+830 <-> 977, 1260, 1861
+831 <-> 669, 760, 946, 1332
+832 <-> 428, 832, 944, 1172
+833 <-> 837, 1008, 1470
+834 <-> 429, 915
+835 <-> 306, 745, 976
+836 <-> 499, 967
+837 <-> 596, 833, 974
+838 <-> 1335
+839 <-> 320, 839, 1703
+840 <-> 1053, 1398, 1760
+841 <-> 1193
+842 <-> 842, 1066, 1108
+843 <-> 1414, 1697, 1894
+844 <-> 337, 438
+845 <-> 1506
+846 <-> 771
+847 <-> 466, 907, 1432
+848 <-> 510, 764
+849 <-> 1063, 1195, 1701
+850 <-> 730, 1551
+851 <-> 1112, 1331, 1479
+852 <-> 1652
+853 <-> 391
+854 <-> 17, 424, 906, 1665
+855 <-> 425, 1082
+856 <-> 301, 463, 727, 1744
+857 <-> 22, 227
+858 <-> 539, 1252, 1472
+859 <-> 232, 1843
+860 <-> 193
+861 <-> 549, 702, 1709, 1884
+862 <-> 1149
+863 <-> 651, 955
+864 <-> 630
+865 <-> 1138
+866 <-> 144, 1111, 1114
+867 <-> 282, 1487, 1835
+868 <-> 1699
+869 <-> 869
+870 <-> 1487
+871 <-> 619
+872 <-> 872
+873 <-> 370, 543, 1968
+874 <-> 750, 874
+875 <-> 234, 1202, 1473
+876 <-> 807, 933, 1741
+877 <-> 1205, 1874
+878 <-> 1831
+879 <-> 534, 1860
+880 <-> 32, 611, 674, 794
+881 <-> 1361, 1750
+882 <-> 572, 1495
+883 <-> 613, 669
+884 <-> 591, 628, 1815
+885 <-> 996, 1237
+886 <-> 314, 1709
+887 <-> 576
+888 <-> 551
+889 <-> 0, 1494
+890 <-> 1100, 1966
+891 <-> 788, 1312
+892 <-> 303, 533, 822, 1334, 1812, 1935
+893 <-> 1723
+894 <-> 272, 1992
+895 <-> 568, 1038
+896 <-> 551, 1425
+897 <-> 1783
+898 <-> 375
+899 <-> 358
+900 <-> 730
+901 <-> 106, 153, 610
+902 <-> 1203
+903 <-> 32, 1935
+904 <-> 1109
+905 <-> 364
+906 <-> 293, 854, 1565
+907 <-> 847, 1139, 1180, 1431, 1563, 1878
+908 <-> 1908
+909 <-> 321, 943
+910 <-> 47, 1067
+911 <-> 1468, 1495
+912 <-> 15
+913 <-> 1692
+914 <-> 922, 1445
+915 <-> 834, 1002
+916 <-> 461
+917 <-> 1177, 1924
+918 <-> 806, 962, 1058, 1419
+919 <-> 44, 82, 1933
+920 <-> 1147, 1539
+921 <-> 393, 458, 1055, 1951
+922 <-> 914, 1271
+923 <-> 204, 207, 1201
+924 <-> 205, 690
+925 <-> 173, 1816
+926 <-> 1279
+927 <-> 927
+928 <-> 781
+929 <-> 154
+930 <-> 144
+931 <-> 972, 1237
+932 <-> 1317
+933 <-> 876, 1756
+934 <-> 51, 405, 1105, 1960
+935 <-> 935, 1674
+936 <-> 491, 1201, 1247
+937 <-> 956, 1576, 1788
+938 <-> 1377, 1733
+939 <-> 121, 1638
+940 <-> 698, 1808
+941 <-> 1665, 1957
+942 <-> 673
+943 <-> 341, 909
+944 <-> 832
+945 <-> 1087, 1340
+946 <-> 824, 831
+947 <-> 555
+948 <-> 959
+949 <-> 1068
+950 <-> 1664
+951 <-> 241, 502, 1151
+952 <-> 40, 537, 1376
+953 <-> 397
+954 <-> 148, 1075, 1364
+955 <-> 863, 1235, 1618, 1724
+956 <-> 937
+957 <-> 101, 1323
+958 <-> 1794, 1972
+959 <-> 643, 948, 1023
+960 <-> 960, 1417
+961 <-> 1278
+962 <-> 370, 918
+963 <-> 481, 712
+964 <-> 1198
+965 <-> 4
+966 <-> 966
+967 <-> 836, 967, 1821
+968 <-> 1513
+969 <-> 128, 232
+970 <-> 529
+971 <-> 1471
+972 <-> 436, 931
+973 <-> 231
+974 <-> 837
+975 <-> 1390
+976 <-> 835
+977 <-> 830
+978 <-> 439, 1687
+979 <-> 527
+980 <-> 980, 1609, 1940
+981 <-> 307, 1671
+982 <-> 574, 1318, 1643
+983 <-> 243
+984 <-> 598
+985 <-> 279
+986 <-> 68
+987 <-> 1060
+988 <-> 1942
+989 <-> 1478
+990 <-> 490, 525, 1838
+991 <-> 41, 1263, 1302
+992 <-> 591
+993 <-> 273, 641
+994 <-> 1026, 1240, 1618
+995 <-> 662, 1545
+996 <-> 885, 1528
+997 <-> 449, 1058
+998 <-> 487
+999 <-> 784, 825
+1000 <-> 728
+1001 <-> 141, 663, 1626, 1681
+1002 <-> 300, 915
+1003 <-> 667
+1004 <-> 227, 459
+1005 <-> 1780
+1006 <-> 234, 1578
+1007 <-> 203, 406
+1008 <-> 617, 833
+1009 <-> 786, 1064
+1010 <-> 1010, 1031, 1919
+1011 <-> 752, 1754
+1012 <-> 7, 723, 1068, 1181
+1013 <-> 36
+1014 <-> 1594
+1015 <-> 707
+1016 <-> 63
+1017 <-> 1511
+1018 <-> 374, 1034
+1019 <-> 131, 1155
+1020 <-> 114
+1021 <-> 1288
+1022 <-> 645
+1023 <-> 959, 1375
+1024 <-> 1024
+1025 <-> 216
+1026 <-> 411, 994
+1027 <-> 515
+1028 <-> 1417
+1029 <-> 304, 724
+1030 <-> 343, 351
+1031 <-> 768, 1010
+1032 <-> 1032
+1033 <-> 521
+1034 <-> 1018
+1035 <-> 235, 1578
+1036 <-> 179, 503, 511, 1036
+1037 <-> 1037, 1044
+1038 <-> 895, 1125
+1039 <-> 547, 725, 1599
+1040 <-> 395
+1041 <-> 816
+1042 <-> 559, 1042
+1043 <-> 168, 1873
+1044 <-> 643, 1037, 1312
+1045 <-> 1232
+1046 <-> 321
+1047 <-> 254
+1048 <-> 1747
+1049 <-> 364
+1050 <-> 1050, 1947, 1963
+1051 <-> 1156
+1052 <-> 4, 1201
+1053 <-> 840
+1054 <-> 1133, 1342, 1537, 1708, 1778
+1055 <-> 71, 921, 1786
+1056 <-> 1672
+1057 <-> 778, 1423, 1787
+1058 <-> 918, 997
+1059 <-> 288, 1337, 1401
+1060 <-> 987, 1781
+1061 <-> 602, 1660
+1062 <-> 316, 1863
+1063 <-> 120, 819, 849
+1064 <-> 1009
+1065 <-> 1065
+1066 <-> 842
+1067 <-> 774, 910, 1089
+1068 <-> 949, 1012
+1069 <-> 1900
+1070 <-> 556
+1071 <-> 1884
+1072 <-> 447, 1122
+1073 <-> 163, 249, 1073, 1237
+1074 <-> 262
+1075 <-> 954, 1075, 1789
+1076 <-> 1076, 1680
+1077 <-> 55, 322
+1078 <-> 160, 547
+1079 <-> 827, 1079
+1080 <-> 377, 425, 1739
+1081 <-> 220, 230
+1082 <-> 855, 1638
+1083 <-> 44
+1084 <-> 302, 736
+1085 <-> 168, 1431
+1086 <-> 1973
+1087 <-> 639, 945
+1088 <-> 672
+1089 <-> 1067, 1190
+1090 <-> 408, 1492
+1091 <-> 1674
+1092 <-> 793
+1093 <-> 1802
+1094 <-> 536
+1095 <-> 1095, 1204
+1096 <-> 279
+1097 <-> 351, 381
+1098 <-> 757, 1519
+1099 <-> 1099, 1752
+1100 <-> 177, 890
+1101 <-> 1145
+1102 <-> 1280
+1103 <-> 190, 1200
+1104 <-> 629
+1105 <-> 100, 934
+1106 <-> 1426
+1107 <-> 78, 1497
+1108 <-> 842
+1109 <-> 507, 904, 1109
+1110 <-> 750
+1111 <-> 866
+1112 <-> 851
+1113 <-> 1113
+1114 <-> 866, 1131, 1861
+1115 <-> 1187, 1629
+1116 <-> 342
+1117 <-> 754
+1118 <-> 1637
+1119 <-> 739
+1120 <-> 1837
+1121 <-> 1133, 1758
+1122 <-> 577, 1072, 1349
+1123 <-> 1359
+1124 <-> 1174
+1125 <-> 1038, 1789
+1126 <-> 1260
+1127 <-> 1213
+1128 <-> 161, 652
+1129 <-> 441
+1130 <-> 4
+1131 <-> 1114
+1132 <-> 1132, 1979
+1133 <-> 1054, 1121, 1253
+1134 <-> 817
+1135 <-> 76, 1606
+1136 <-> 765, 777, 1860
+1137 <-> 434
+1138 <-> 865, 1280, 1471, 1736
+1139 <-> 74, 907
+1140 <-> 108, 378
+1141 <-> 178
+1142 <-> 655, 717
+1143 <-> 446
+1144 <-> 221
+1145 <-> 476, 705, 1101, 1271, 1956
+1146 <-> 474, 1179, 1936
+1147 <-> 920, 1147
+1148 <-> 1148, 1795
+1149 <-> 862, 1799
+1150 <-> 559, 684, 1797
+1151 <-> 951
+1152 <-> 1229
+1153 <-> 1515, 1530
+1154 <-> 1154
+1155 <-> 1019, 1300
+1156 <-> 164, 1051, 1156
+1157 <-> 18, 1157
+1158 <-> 1208
+1159 <-> 1651
+1160 <-> 567, 1510, 1710
+1161 <-> 1161, 1427, 1590
+1162 <-> 206, 229, 1561
+1163 <-> 1388
+1164 <-> 741, 1494
+1165 <-> 1217
+1166 <-> 123, 276
+1167 <-> 1262, 1547
+1168 <-> 80, 531, 696
+1169 <-> 362, 757, 1504
+1170 <-> 1854
+1171 <-> 1171, 1898
+1172 <-> 832
+1173 <-> 1173, 1315
+1174 <-> 1124, 1174, 1831
+1175 <-> 202, 452
+1176 <-> 330, 335, 1761
+1177 <-> 917
+1178 <-> 155, 567
+1179 <-> 224, 1146
+1180 <-> 907, 1661
+1181 <-> 1012
+1182 <-> 176
+1183 <-> 690, 722, 788
+1184 <-> 645
+1185 <-> 487
+1186 <-> 1659
+1187 <-> 348, 1115, 1670
+1188 <-> 275, 803
+1189 <-> 1689
+1190 <-> 75, 1089
+1191 <-> 285
+1192 <-> 1744
+1193 <-> 477, 515, 841
+1194 <-> 1308
+1195 <-> 761, 849
+1196 <-> 130, 1993
+1197 <-> 144
+1198 <-> 613, 964, 1329
+1199 <-> 1389
+1200 <-> 1103
+1201 <-> 923, 936, 1052
+1202 <-> 875
+1203 <-> 490, 902, 1692
+1204 <-> 718, 1095, 1245
+1205 <-> 263, 333, 877
+1206 <-> 1311
+1207 <-> 415, 1883
+1208 <-> 445, 1158
+1209 <-> 550, 1640
+1210 <-> 12, 1210, 1428
+1211 <-> 460, 1529
+1212 <-> 52, 159, 1493, 1819
+1213 <-> 1127, 1213
+1214 <-> 1214, 1436
+1215 <-> 266, 1758
+1216 <-> 729, 739
+1217 <-> 141, 749, 1165, 1315
+1218 <-> 599, 1595
+1219 <-> 740, 1549
+1220 <-> 588, 1374
+1221 <-> 405
+1222 <-> 1966
+1223 <-> 119
+1224 <-> 1528
+1225 <-> 1314
+1226 <-> 86, 515
+1227 <-> 1681
+1228 <-> 1228
+1229 <-> 0, 1152, 1374
+1230 <-> 1453
+1231 <-> 223, 488
+1232 <-> 1045, 1261
+1233 <-> 1759
+1234 <-> 360
+1235 <-> 283, 955, 1241, 1783
+1236 <-> 1356
+1237 <-> 600, 885, 931, 1073
+1238 <-> 370, 1602
+1239 <-> 546, 1373
+1240 <-> 994
+1241 <-> 1235, 1392
+1242 <-> 7, 59, 821, 1945
+1243 <-> 1296
+1244 <-> 7, 1300, 1434
+1245 <-> 1204, 1347
+1246 <-> 374, 555, 1508
+1247 <-> 109, 936
+1248 <-> 785, 1715
+1249 <-> 238
+1250 <-> 1600, 1623
+1251 <-> 1251
+1252 <-> 858
+1253 <-> 392, 1133
+1254 <-> 35, 1394
+1255 <-> 575
+1256 <-> 214, 1607, 1685
+1257 <-> 169
+1258 <-> 81, 1264, 1320
+1259 <-> 811, 1425
+1260 <-> 830, 1126
+1261 <-> 571, 1232
+1262 <-> 1167, 1862
+1263 <-> 540, 991
+1264 <-> 1258, 1651
+1265 <-> 139, 1569
+1266 <-> 708
+1267 <-> 1267
+1268 <-> 721
+1269 <-> 276, 676, 1759
+1270 <-> 467, 1270, 1916
+1271 <-> 225, 922, 1145, 1700
+1272 <-> 99
+1273 <-> 1302
+1274 <-> 1966
+1275 <-> 525
+1276 <-> 791, 1834
+1277 <-> 450, 1474, 1645
+1278 <-> 185, 961
+1279 <-> 458, 926
+1280 <-> 209, 1102, 1138
+1281 <-> 208, 462, 1943
+1282 <-> 694, 1522
+1283 <-> 111, 119, 1407
+1284 <-> 182, 1996
+1285 <-> 287
+1286 <-> 647, 1286, 1715
+1287 <-> 132
+1288 <-> 222, 1021, 1398
+1289 <-> 724
+1290 <-> 208, 260, 317
+1291 <-> 1498
+1292 <-> 88
+1293 <-> 387, 715, 1322, 1519, 1645
+1294 <-> 445, 513, 1504
+1295 <-> 766
+1296 <-> 1243, 1379, 1964
+1297 <-> 38, 1669
+1298 <-> 1906
+1299 <-> 18, 1804
+1300 <-> 1155, 1244
+1301 <-> 1371, 1453
+1302 <-> 991, 1273
+1303 <-> 375, 504, 1948
+1304 <-> 1667, 1933
+1305 <-> 102, 151, 665
+1306 <-> 266
+1307 <-> 179
+1308 <-> 34, 1194
+1309 <-> 563
+1310 <-> 526, 789
+1311 <-> 1206, 1311, 1769
+1312 <-> 891, 1044
+1313 <-> 169
+1314 <-> 151, 1225
+1315 <-> 42, 1173, 1217
+1316 <-> 1316
+1317 <-> 932, 1805
+1318 <-> 187, 373, 982
+1319 <-> 41, 220, 1948
+1320 <-> 1258, 1859
+1321 <-> 651
+1322 <-> 1293
+1323 <-> 957, 1472
+1324 <-> 1324
+1325 <-> 1325
+1326 <-> 803, 1846
+1327 <-> 753
+1328 <-> 1879
+1329 <-> 1198
+1330 <-> 553, 1330
+1331 <-> 392, 851
+1332 <-> 396, 831
+1333 <-> 210
+1334 <-> 892
+1335 <-> 838, 1552, 1568
+1336 <-> 1336
+1337 <-> 1059
+1338 <-> 310, 544
+1339 <-> 1897
+1340 <-> 945
+1341 <-> 489
+1342 <-> 137, 1054
+1343 <-> 1343
+1344 <-> 1946
+1345 <-> 1345
+1346 <-> 652
+1347 <-> 1245, 1914, 1930
+1348 <-> 787, 1591
+1349 <-> 669, 1122
+1350 <-> 304, 1790
+1351 <-> 587, 1997
+1352 <-> 20, 614
+1353 <-> 1738
+1354 <-> 413, 1608
+1355 <-> 522, 1816, 1917
+1356 <-> 1236, 1450
+1357 <-> 431, 1575
+1358 <-> 500
+1359 <-> 1123, 1599
+1360 <-> 1370, 1385
+1361 <-> 1, 881
+1362 <-> 355, 1611, 1952
+1363 <-> 69
+1364 <-> 954
+1365 <-> 1948
+1366 <-> 30, 1470
+1367 <-> 1527
+1368 <-> 724
+1369 <-> 277, 1482
+1370 <-> 1360
+1371 <-> 642, 1301, 1478, 1485
+1372 <-> 1372, 1594
+1373 <-> 1239
+1374 <-> 79, 1220, 1229
+1375 <-> 764, 771, 1023
+1376 <-> 952
+1377 <-> 938, 1520, 1730
+1378 <-> 1378, 1411, 1823
+1379 <-> 1296, 1832
+1380 <-> 1380
+1381 <-> 673
+1382 <-> 1382
+1383 <-> 195, 586
+1384 <-> 542
+1385 <-> 215, 1360
+1386 <-> 1386
+1387 <-> 1536
+1388 <-> 311, 402, 1163
+1389 <-> 251, 1199
+1390 <-> 322, 975
+1391 <-> 172, 407, 1453
+1392 <-> 1241, 1587
+1393 <-> 419, 823, 1636
+1394 <-> 1254, 1588, 1699
+1395 <-> 401, 1621
+1396 <-> 1396, 1870
+1397 <-> 1629
+1398 <-> 840, 1288
+1399 <-> 1399, 1932
+1400 <-> 721
+1401 <-> 1059
+1402 <-> 1402
+1403 <-> 33
+1404 <-> 1449, 1632, 1832
+1405 <-> 1634
+1406 <-> 1726
+1407 <-> 265, 1283, 1999
+1408 <-> 39, 336, 426
+1409 <-> 75, 147, 654
+1410 <-> 691, 1780
+1411 <-> 1378
+1412 <-> 1447, 1759
+1413 <-> 616, 691
+1414 <-> 843
+1415 <-> 1415
+1416 <-> 197, 271
+1417 <-> 132, 960, 1028
+1418 <-> 1418, 1426
+1419 <-> 918, 1560
+1420 <-> 789
+1421 <-> 629, 715
+1422 <-> 391, 640
+1423 <-> 781, 1057
+1424 <-> 1614
+1425 <-> 21, 896, 1259
+1426 <-> 1106, 1418
+1427 <-> 1161
+1428 <-> 1210, 1677
+1429 <-> 131
+1430 <-> 1822
+1431 <-> 907, 1085, 1846
+1432 <-> 817, 847
+1433 <-> 75
+1434 <-> 1244
+1435 <-> 484, 808
+1436 <-> 1214
+1437 <-> 418
+1438 <-> 57
+1439 <-> 1469, 1824
+1440 <-> 237
+1441 <-> 1722
+1442 <-> 424, 1678
+1443 <-> 144
+1444 <-> 579, 643, 1869
+1445 <-> 914
+1446 <-> 1524, 1728
+1447 <-> 1412, 1962
+1448 <-> 1485
+1449 <-> 1404
+1450 <-> 1356, 1647
+1451 <-> 460, 1907, 1967
+1452 <-> 445, 446
+1453 <-> 56, 133, 638, 1230, 1301, 1391
+1454 <-> 1994
+1455 <-> 788
+1456 <-> 1914
+1457 <-> 769
+1458 <-> 1458
+1459 <-> 700, 1796
+1460 <-> 1799
+1461 <-> 15, 436
+1462 <-> 1678
+1463 <-> 83, 1553, 1684
+1464 <-> 35
+1465 <-> 1471
+1466 <-> 175, 430
+1467 <-> 539, 702
+1468 <-> 281, 911, 1475
+1469 <-> 366, 426, 478, 1439, 1524
+1470 <-> 833, 1366
+1471 <-> 971, 1138, 1465
+1472 <-> 560, 858, 1323, 1937
+1473 <-> 506, 875
+1474 <-> 1277, 1937
+1475 <-> 701, 1468
+1476 <-> 464, 522
+1477 <-> 1785
+1478 <-> 989, 1371
+1479 <-> 409, 851
+1480 <-> 1677
+1481 <-> 463
+1482 <-> 517, 1369, 1482
+1483 <-> 102, 218
+1484 <-> 532, 1531, 1735
+1485 <-> 400, 1371, 1448
+1486 <-> 453
+1487 <-> 867, 870, 1577, 1584
+1488 <-> 1488
+1489 <-> 16, 327
+1490 <-> 418
+1491 <-> 7, 1589
+1492 <-> 823, 1090
+1493 <-> 1212, 1519, 1675
+1494 <-> 775, 889, 1164
+1495 <-> 882, 911
+1496 <-> 386, 1496
+1497 <-> 269, 455, 1107
+1498 <-> 9, 1291, 1758
+1499 <-> 1685, 1893
+1500 <-> 1657
+1501 <-> 244, 287
+1502 <-> 1951
+1503 <-> 112
+1504 <-> 1169, 1294
+1505 <-> 1987
+1506 <-> 845, 1905
+1507 <-> 1507
+1508 <-> 1246
+1509 <-> 41
+1510 <-> 195, 789, 1160, 1980
+1511 <-> 658, 1017
+1512 <-> 1990
+1513 <-> 968, 1513, 1612
+1514 <-> 1514
+1515 <-> 1153, 1632
+1516 <-> 280
+1517 <-> 759
+1518 <-> 1837
+1519 <-> 80, 82, 1098, 1293, 1493
+1520 <-> 1377, 1978
+1521 <-> 1521
+1522 <-> 1282
+1523 <-> 1749, 1876
+1524 <-> 660, 1446, 1469, 1535, 1729
+1525 <-> 283, 713
+1526 <-> 22, 1767
+1527 <-> 535, 1367, 1889
+1528 <-> 996, 1224
+1529 <-> 1211, 1736
+1530 <-> 1153
+1531 <-> 451, 670, 1484
+1532 <-> 46
+1533 <-> 62, 143, 530
+1534 <-> 117, 1992
+1535 <-> 1524
+1536 <-> 342, 1387
+1537 <-> 1054
+1538 <-> 302, 1589
+1539 <-> 576, 920
+1540 <-> 668, 731
+1541 <-> 1639
+1542 <-> 1542
+1543 <-> 1702
+1544 <-> 1927
+1545 <-> 995
+1546 <-> 92, 1890
+1547 <-> 40, 1167
+1548 <-> 796
+1549 <-> 110, 337, 1219
+1550 <-> 46, 667
+1551 <-> 497, 850
+1552 <-> 526, 1335
+1553 <-> 464, 635, 1463
+1554 <-> 580, 1696
+1555 <-> 1556, 1648, 1867
+1556 <-> 180, 1555, 1676
+1557 <-> 313, 1831
+1558 <-> 249
+1559 <-> 501
+1560 <-> 1419
+1561 <-> 1162
+1562 <-> 271, 388
+1563 <-> 597, 907
+1564 <-> 239
+1565 <-> 906, 1854
+1566 <-> 465
+1567 <-> 393, 619
+1568 <-> 1335, 1745
+1569 <-> 658, 1265, 1651
+1570 <-> 475
+1571 <-> 310, 323, 609
+1572 <-> 540, 716
+1573 <-> 738
+1574 <-> 531
+1575 <-> 597, 818, 1357
+1576 <-> 937
+1577 <-> 456, 1487, 1630
+1578 <-> 1006, 1035
+1579 <-> 1704
+1580 <-> 827
+1581 <-> 286, 703, 1888
+1582 <-> 294
+1583 <-> 1907
+1584 <-> 1487
+1585 <-> 1955
+1586 <-> 1586, 1641
+1587 <-> 1392
+1588 <-> 522, 1394
+1589 <-> 1491, 1538, 1589
+1590 <-> 1161, 1642, 1946
+1591 <-> 4, 617, 1348
+1592 <-> 68
+1593 <-> 356, 466
+1594 <-> 826, 1014, 1372
+1595 <-> 1218
+1596 <-> 78
+1597 <-> 640
+1598 <-> 422
+1599 <-> 1039, 1359
+1600 <-> 1250
+1601 <-> 113, 1631
+1602 <-> 1238
+1603 <-> 1603
+1604 <-> 1604
+1605 <-> 1980
+1606 <-> 1135, 1828
+1607 <-> 1256, 1607
+1608 <-> 1354
+1609 <-> 980, 1864
+1610 <-> 1610
+1611 <-> 583, 1362
+1612 <-> 309, 367, 1513
+1613 <-> 270, 1620
+1614 <-> 1424, 1688
+1615 <-> 1615
+1616 <-> 1884
+1617 <-> 806, 1763
+1618 <-> 955, 994, 1897
+1619 <-> 1622
+1620 <-> 538, 584, 1613
+1621 <-> 1395, 1621
+1622 <-> 452, 1619
+1623 <-> 188, 1250
+1624 <-> 148
+1625 <-> 519, 618, 1625, 1765
+1626 <-> 213, 1001
+1627 <-> 1929
+1628 <-> 6, 305
+1629 <-> 558, 1115, 1397
+1630 <-> 1577
+1631 <-> 779, 1601
+1632 <-> 1404, 1515
+1633 <-> 336
+1634 <-> 762, 1405, 1734
+1635 <-> 1635
+1636 <-> 257, 649, 1393
+1637 <-> 167, 329, 1118
+1638 <-> 939, 1082
+1639 <-> 1541, 1639
+1640 <-> 1209
+1641 <-> 1586
+1642 <-> 567, 1590
+1643 <-> 982
+1644 <-> 408, 509
+1645 <-> 1277, 1293
+1646 <-> 1836, 1875
+1647 <-> 1450, 1772
+1648 <-> 1555, 1946
+1649 <-> 1743
+1650 <-> 627, 1720
+1651 <-> 1159, 1264, 1569
+1652 <-> 852, 1930
+1653 <-> 1653
+1654 <-> 677
+1655 <-> 85, 733
+1656 <-> 1875
+1657 <-> 261, 1500, 1703
+1658 <-> 693, 1679
+1659 <-> 1186, 1659
+1660 <-> 673, 1061
+1661 <-> 662, 1180
+1662 <-> 483
+1663 <-> 1663, 1904
+1664 <-> 196, 950, 1664
+1665 <-> 144, 854, 941
+1666 <-> 1666
+1667 <-> 1304, 1890
+1668 <-> 488
+1669 <-> 1297
+1670 <-> 78, 1187
+1671 <-> 215, 981
+1672 <-> 145, 358, 719, 1056
+1673 <-> 1673
+1674 <-> 25, 935, 1091
+1675 <-> 1493
+1676 <-> 190, 1556
+1677 <-> 1428, 1480
+1678 <-> 1442, 1462, 1987
+1679 <-> 577, 1658
+1680 <-> 16, 1076
+1681 <-> 1001, 1227
+1682 <-> 71
+1683 <-> 90
+1684 <-> 479, 1463, 1852
+1685 <-> 1256, 1499
+1686 <-> 94
+1687 <-> 687, 978, 1787
+1688 <-> 332, 1614, 1688
+1689 <-> 758, 1189, 1779
+1690 <-> 477
+1691 <-> 1691, 1986
+1692 <-> 166, 585, 813, 913, 1203, 1913
+1693 <-> 671
+1694 <-> 1711
+1695 <-> 89, 1795
+1696 <-> 1554
+1697 <-> 147, 843, 1900
+1698 <-> 212, 444, 1793
+1699 <-> 676, 868, 1394, 1705
+1700 <-> 87, 1271
+1701 <-> 849
+1702 <-> 222, 692, 1543
+1703 <-> 839, 1657
+1704 <-> 314, 498, 1579
+1705 <-> 1699
+1706 <-> 89, 1993
+1707 <-> 1990, 1994
+1708 <-> 1054, 1892
+1709 <-> 861, 886
+1710 <-> 1160
+1711 <-> 1694, 1737
+1712 <-> 1712
+1713 <-> 714, 1935
+1714 <-> 600
+1715 <-> 217, 1248, 1286
+1716 <-> 808
+1717 <-> 278, 1914
+1718 <-> 580
+1719 <-> 669
+1720 <-> 1650, 1762, 1856
+1721 <-> 422, 1918
+1722 <-> 1441, 1722
+1723 <-> 893, 1915
+1724 <-> 508, 750, 955
+1725 <-> 1725
+1726 <-> 1406, 1959
+1727 <-> 1797
+1728 <-> 14, 1446
+1729 <-> 1524
+1730 <-> 1377, 1737
+1731 <-> 104, 749
+1732 <-> 129, 1908
+1733 <-> 174, 655, 938
+1734 <-> 816, 1634, 1734
+1735 <-> 538, 1484
+1736 <-> 0, 1138, 1529
+1737 <-> 1711, 1730
+1738 <-> 26, 1353, 1757
+1739 <-> 302, 1080
+1740 <-> 118, 257
+1741 <-> 152, 219, 876
+1742 <-> 1841, 1945
+1743 <-> 333, 1649
+1744 <-> 659, 743, 856, 1192
+1745 <-> 1568
+1746 <-> 1746
+1747 <-> 579, 1048
+1748 <-> 283
+1749 <-> 189, 350, 1523, 1848, 1894
+1750 <-> 881
+1751 <-> 344
+1752 <-> 1099
+1753 <-> 1753
+1754 <-> 1011
+1755 <-> 1755, 1939
+1756 <-> 933
+1757 <-> 1738
+1758 <-> 1121, 1215, 1498
+1759 <-> 1233, 1269, 1412
+1760 <-> 198, 679, 840
+1761 <-> 1176
+1762 <-> 713, 1720
+1763 <-> 1617
+1764 <-> 613
+1765 <-> 1625
+1766 <-> 99
+1767 <-> 623, 751, 1526
+1768 <-> 82
+1769 <-> 1311, 1921
+1770 <-> 565, 1995
+1771 <-> 77, 1771
+1772 <-> 805, 1647, 1772
+1773 <-> 1773, 1826
+1774 <-> 303
+1775 <-> 239, 259
+1776 <-> 225
+1777 <-> 393
+1778 <-> 482, 699, 709, 1054
+1779 <-> 264, 1689
+1780 <-> 61, 194, 707, 1005, 1410, 1999
+1781 <-> 165, 1060, 1978
+1782 <-> 264
+1783 <-> 897, 1235, 1845
+1784 <-> 1784
+1785 <-> 1477, 1915
+1786 <-> 1055
+1787 <-> 1057, 1687, 1899
+1788 <-> 498, 937, 1859
+1789 <-> 1075, 1125
+1790 <-> 646, 1350
+1791 <-> 617
+1792 <-> 1855
+1793 <-> 1698
+1794 <-> 958
+1795 <-> 1148, 1695
+1796 <-> 779, 1459, 1857
+1797 <-> 1150, 1727
+1798 <-> 500
+1799 <-> 795, 1149, 1460
+1800 <-> 368, 1800
+1801 <-> 220
+1802 <-> 99, 1093
+1803 <-> 1810
+1804 <-> 1299
+1805 <-> 292, 527, 1317
+1806 <-> 443, 1865
+1807 <-> 795, 1911
+1808 <-> 940
+1809 <-> 122, 595
+1810 <-> 345, 1803
+1811 <-> 1980
+1812 <-> 892
+1813 <-> 421, 606
+1814 <-> 612, 780
+1815 <-> 656, 884
+1816 <-> 925, 1355
+1817 <-> 635, 666
+1818 <-> 29, 206
+1819 <-> 1212
+1820 <-> 1874
+1821 <-> 227, 967
+1822 <-> 736, 739, 1430
+1823 <-> 1378
+1824 <-> 68, 1439
+1825 <-> 700
+1826 <-> 557, 1773
+1827 <-> 98, 1971
+1828 <-> 1606, 1865
+1829 <-> 449
+1830 <-> 1830
+1831 <-> 20, 878, 1174, 1557
+1832 <-> 1379, 1404, 1832
+1833 <-> 107
+1834 <-> 423, 560, 1276
+1835 <-> 867
+1836 <-> 118, 1646
+1837 <-> 47, 1120, 1518
+1838 <-> 243, 990
+1839 <-> 1839
+1840 <-> 478
+1841 <-> 1742
+1842 <-> 565
+1843 <-> 594, 747, 859
+1844 <-> 461
+1845 <-> 1783
+1846 <-> 1326, 1431
+1847 <-> 633, 1888
+1848 <-> 1749
+1849 <-> 24, 48, 292, 1851
+1850 <-> 440, 782
+1851 <-> 1849
+1852 <-> 1684
+1853 <-> 1853
+1854 <-> 557, 1170, 1565
+1855 <-> 70, 1792
+1856 <-> 1720
+1857 <-> 1796
+1858 <-> 417
+1859 <-> 1320, 1788
+1860 <-> 36, 879, 1136
+1861 <-> 830, 1114
+1862 <-> 416, 1262
+1863 <-> 28, 769, 787, 1062
+1864 <-> 1609, 1920, 1953
+1865 <-> 189, 1806, 1828, 1969
+1866 <-> 451
+1867 <-> 1555
+1868 <-> 1868
+1869 <-> 1444
+1870 <-> 1396
+1871 <-> 1939
+1872 <-> 1914
+1873 <-> 694, 1043
+1874 <-> 241, 877, 1820
+1875 <-> 1646, 1656
+1876 <-> 1523
+1877 <-> 1877
+1878 <-> 159, 688, 907
+1879 <-> 1328, 1879
+1880 <-> 415
+1881 <-> 65
+1882 <-> 201
+1883 <-> 812, 1207
+1884 <-> 731, 861, 1071, 1616
+1885 <-> 753, 1885
+1886 <-> 75
+1887 <-> 766, 807
+1888 <-> 240, 1581, 1847
+1889 <-> 800, 1527
+1890 <-> 1546, 1667
+1891 <-> 186, 548
+1892 <-> 1708
+1893 <-> 1499
+1894 <-> 475, 843, 1749
+1895 <-> 622, 1895, 1978
+1896 <-> 334
+1897 <-> 1339, 1618, 1949
+1898 <-> 1171
+1899 <-> 1787
+1900 <-> 1069, 1697
+1901 <-> 142
+1902 <-> 291, 305
+1903 <-> 745
+1904 <-> 1663
+1905 <-> 829, 1506
+1906 <-> 316, 767, 1298, 1999
+1907 <-> 183, 1451, 1583
+1908 <-> 908, 1732
+1909 <-> 62
+1910 <-> 1999
+1911 <-> 364, 1807
+1912 <-> 372, 1912
+1913 <-> 161, 601, 1692
+1914 <-> 1347, 1456, 1717, 1872
+1915 <-> 760, 1723, 1785
+1916 <-> 1270
+1917 <-> 1355
+1918 <-> 1721
+1919 <-> 590, 1010
+1920 <-> 414, 1864
+1921 <-> 1769
+1922 <-> 232
+1923 <-> 238, 271, 1923
+1924 <-> 571, 917
+1925 <-> 556, 1925
+1926 <-> 129, 581
+1927 <-> 360, 1544
+1928 <-> 289
+1929 <-> 1627, 1929
+1930 <-> 181, 1347, 1652
+1931 <-> 469, 1931
+1932 <-> 1399
+1933 <-> 919, 1304
+1934 <-> 290
+1935 <-> 803, 892, 903, 1713
+1936 <-> 1146
+1937 <-> 146, 1472, 1474
+1938 <-> 149
+1939 <-> 88, 1755, 1871
+1940 <-> 980
+1941 <-> 548, 828
+1942 <-> 613, 988
+1943 <-> 1281
+1944 <-> 239, 326, 530
+1945 <-> 49, 1242, 1742
+1946 <-> 1344, 1590, 1648
+1947 <-> 1050
+1948 <-> 607, 1303, 1319, 1365
+1949 <-> 1897
+1950 <-> 1950
+1951 <-> 553, 921, 1502
+1952 <-> 163, 1362
+1953 <-> 1864
+1954 <-> 495, 620
+1955 <-> 735, 1585
+1956 <-> 11, 1145
+1957 <-> 941
+1958 <-> 398, 668
+1959 <-> 340, 1726
+1960 <-> 934
+1961 <-> 641
+1962 <-> 1447
+1963 <-> 112, 1050
+1964 <-> 1296
+1965 <-> 61
+1966 <-> 890, 1222, 1274
+1967 <-> 545, 550, 729, 1451
+1968 <-> 873
+1969 <-> 704, 1865
+1970 <-> 393
+1971 <-> 1827
+1972 <-> 326, 958
+1973 <-> 1086, 1973
+1974 <-> 319, 1974
+1975 <-> 452
+1976 <-> 155
+1977 <-> 410
+1978 <-> 1520, 1781, 1895
+1979 <-> 1132
+1980 <-> 1510, 1605, 1811
+1981 <-> 184
+1982 <-> 39
+1983 <-> 1983
+1984 <-> 379, 494
+1985 <-> 95
+1986 <-> 1691
+1987 <-> 1505, 1678
+1988 <-> 124, 516, 784
+1989 <-> 322
+1990 <-> 1512, 1707
+1991 <-> 226
+1992 <-> 894, 1534
+1993 <-> 1196, 1706
+1994 <-> 16, 1454, 1707
+1995 <-> 682, 1770
+1996 <-> 1284
+1997 <-> 153, 308, 1351
+1998 <-> 5, 235, 428, 524
+1999 <-> 1407, 1780, 1906, 1910
diff --git a/day12.cc b/day12.cc
new file mode 100644
index 0000000..8d757eb
--- /dev/null
+++ b/day12.cc
@@ -0,0 +1,91 @@
+#ifdef BOOST
+
+#include <iostream>
+#include <optional>
+
+// Using boost-1.65.1
+#include <boost/config.hpp>
+#include <boost/graph/adjacency_list.hpp>
+#include <boost/graph/connected_components.hpp>
+#include <boost/tokenizer.hpp>
+
+using namespace std;
+
+using undirected_graph =
+    boost::adjacency_list<boost::vecS, boost::vecS, boost::undirectedS>;
+
+int
+main()
+{
+	undirected_graph G;
+
+	for (string line; getline(cin, line); ) {
+		optional<int> last;
+		for (string s : boost::tokenizer<>(line)) {
+			int i = stoi(s);
+			if (last)
+				add_edge(*last, i, G);
+			last = i;
+		}
+	}
+
+	vector<int> component(num_vertices(G));
+	int n = connected_components(G, &component[0]);
+	cout << count(begin(component), end(component), component[0]) << endl;
+	cout << n << endl;
+}
+
+// 134
+// 193
+
+#else //////////////////////////////////////////////////////////////////////
+
+#include <algorithm>
+#include <deque>
+#include <iostream>
+#include <sstream>
+#include <string>
+#include <vector>
+
+using namespace std;
+
+// bfs approach without recursion
+// adapted from https://www.reddit.com/r/adventofcode/comments/7j89tr/x/dr4iya8/
+
+int main()
+{
+	vector<vector<int>> edges;
+
+	for (string line; getline(cin, line); ) {		
+		istringstream line_stream{line};
+		int vertex_a, vertex_b;
+		string _;
+		line_stream >> vertex_a >> _;
+		for (edges.emplace_back();  // assumes lines arrive in order
+		     line_stream >> vertex_b;
+		     line_stream >> _)
+			edges[vertex_a].emplace_back(vertex_b);
+	}
+
+	vector<int> comp(size(edges), -1);
+	int n = 0;
+
+	for (auto vertex = begin(comp);
+	     vertex != end(comp);
+	     ++n, vertex = find(begin(comp), end(comp), -1)) {
+		deque<long> queue{distance(begin(comp), vertex)};
+		while (!empty(queue)) {
+			int v = queue.front();
+			queue.pop_front();
+			comp[v] = n;
+			copy_if(begin(edges[v]), end(edges[v]),
+			    back_inserter(queue),
+			    [&](int v){ return comp[v] == -1; });
+		}
+	}
+
+	cout << count(begin(comp), end(comp), 0) << endl;
+	cout << n << endl;
+}
+
+#endif
diff --git a/day12.k b/day12.k
new file mode 100644
index 0000000..aab505f
--- /dev/null
+++ b/day12.k
@@ -0,0 +1,8 @@
+m:(.:'(d?'" ")#'d)!.:'(1+d?'">")_'d:0:`day12
+
+#{?,/x,m x}/,0
+
+-1+#{x^{?,/x,m x}/*x}\!m    / thanks @streetster_
+
+#?{v@<v:?,/x,m x}/',:'!m    / mine, but slow
+\\