Scala, score 137
Edit:
The code here oversimplifies the problem.
Thus, the solution works for many inputs, but not for all.
Original Post:
Basic Idea
Simpler problem
Let's simplify the problem first:
We seek for a string containing all \$n\$ first primes, as short as possible. (not necessarily the lowest number)
First, we generate the set of primes, and remove all, that are already substrings of others.
Then, we can apply multiple rules, i.e. if there is only one string ending in a sequence and only one starting with that same sequence, we can merge them. Another one would be that if a string starts and ends with the same sequence (as 101 does), we can append/prepend it to another string without changing that's ends. (Those rules only yield under certain conditions, so be careful when to apply them)
If we have no remaining equal ends/starts of strings, we can just concatenate them and have a minimal-length string containing all \$n\$ first primes.
Those rules are not trivial to figure out, but most of the time, they are sufficient to solve this problem in (I think..) \$O(n^4)\$ or less.
There are cases (i.e. in the generation for \$n=128\$), where those rules are not sufficient. There, we have to fall back to an algorithm taking NP time.
The real problem
With the algorithm from above, we can calculate the length \$k\$ of the result.
Imagine we had a god-given start of the sequence:
10103..............
^ we want to know this digit
Then we can just take our algorithm from the simplified problem to test if there is a sequence starting with 10103
0
, containing all \$n\$ primes and having length \$k\$.
If there is, we can continue with the next digit, because the smallest number seeked cannot be bigger than that.
If not, we increase the last digit, so we get 10103
1
and test with that.
Starting with the empty string, we can generate the wanted number in \$O(n\cdot\log(n))\times\text{the time for the simpler algorithm}\$.
Thus, if the rules in the algorithm above were always sufficient, the problem would have been shown not to be NP-hard.
The "TSP-solving" part in my program is done only by simplification, if possible (that is possible for the first 127 numbers). (When it is possible, we could translate the tail-recursive findSeq
to a loop, so we could prove it not to be NP-hard). It only gets tricky, if simplification is not sufficient, what happens the first time for \$n=128\$.
Try online
Scastie timeouts after 30s, so it stops at \$n\approx75\$
https://scastie.scala-lang.org/Y9aPRusTRY2ve4avaKAsrA
Code
import scala.annotation.tailrec
object Better {
var primeLength: Int = 3
var knownLengths: Map[(String,List[String]), Int] = Map()
def main(args: Array[String]): Unit = {
val start = System.currentTimeMillis()
var last = ""
Stream.from(1).foreach { i =>
primeLength = primeList(i-1).toString.length
val pcn = if (last.contains(primeList(i-1).toString)) last else calcPrimeContainingNumber(i)
last = pcn
if (System.currentTimeMillis() - start > 300 * 1000) // reached the time limit while calculating the last number, so, discard it and exit
return
println(i + ": " + pcn)
}
}
def calcPrimeContainingNumber(n: Int): String = {
val numbers = relevantNumbers(n)
generateIntegerContainingSeq(numbers, numOfDigitsRequired(numbers, "X"), "X").tail
}
def relevantNumbers(n: Int): List[String] = {
val primesRaw = primeList.take(n)
val primes = primesRaw.map(_.toString).foldRight(List[String]())((i, l) => if (l.exists(_.contains(i))) l else i +: l)
primes.sorted
}
@tailrec
def generateIntegerContainingSeq(numbers: List[String], maxDigits: Int, soFar: String): String = {
if (numbers.isEmpty)
return soFar
val nextDigit = (0 to 9).find(i => numOfDigitsRequired(numbers.filterNot((soFar + i).contains), soFar + i) == maxDigits).get
generateIntegerContainingSeq(numbers.filterNot((soFar + nextDigit).contains), maxDigits, soFar + nextDigit)
}
def numOfDigitsRequired(numbers: List[String], soFar: String): Int = {
soFar.length +
knownLengths.getOrElse((soFar.takeRight(primeLength - 1), numbers), {
val len = findAnySeq(soFar :: numbers).length - soFar.length
knownLengths += (soFar.takeRight(primeLength - 1), numbers) -> len
len
})
}
def findAnySeq(numbers: List[String]): String = {
val tails = numbers.flatMap(_.tails.drop(1).toSeq.dropRight(1)).distinct
.filter(t => numbers.exists(n1 => n1.startsWith(t) && numbers.exists(n2 => n1 != n2 && n2.endsWith(t)))) // require different strings for start & end
.sorted.sortBy(-_.length)
val safeTails = tails.filterNot(t1 => tails.exists(t2 => t1 != t2 && t2.contains(t1))) // all those which are not substring of another tail
@inline def merge(e: String, s: String, i: Int): String = findAnySeq((numbers diff List(e, s)) :+ (e + s.drop(i)))
safeTails.foreach { overlap =>
val ending = numbers.filter(_.endsWith(overlap))
val starting = numbers.filter(_.startsWith(overlap))
if (ending.nonEmpty && starting.nonEmpty) {
if (ending.size == 1 && starting.size == 1 && ending != starting) { // there is really only one way
return merge(ending.head, starting.head, overlap.length)
}
val startingAndEnding = ending.filter(_.startsWith(overlap))
if (startingAndEnding.nonEmpty && ending.size > 1) {
return merge(ending.filter(_ != startingAndEnding.head).head, startingAndEnding.head, overlap.length)
} else if (startingAndEnding.nonEmpty && starting.size > 1) {
return merge(startingAndEnding.head, starting.filter(_ != startingAndEnding.head).head, overlap.length)
}
}
}
@inline def startsRelevant(n: String): Boolean = tails.exists(n.startsWith)
@inline def endsRelevant(n: String): Boolean = tails.exists(n.endsWith)
safeTails.foreach { overlap =>
val ending = numbers.filter(_.endsWith(overlap))
val starting = numbers.filter(_.startsWith(overlap))
ending.find(!startsRelevant(_)).foreach { e =>
starting.find(endsRelevant)
.orElse(starting.headOption) // if there is no relevant starting, take head (ending is already shown to be irrelevant)
.foreach { s =>
return merge(e, s, overlap.length)
}
}
ending.find(startsRelevant).foreach { e =>
starting.find(!endsRelevant(_)).foreach { s =>
return merge(e, s, overlap.length)
}
}
}
safeTails.foreach { overlap =>
val ending = numbers.filter(_.endsWith(overlap))
val starting = numbers.filter(_.startsWith(overlap))
return ending
.flatMap(e => starting.filter(_ != e).map(s => merge(e, s, overlap.length)))
.minBy(_.length)
}
if (tails.nonEmpty)
throw new Error("that was unexpected :( " + numbers)
numbers.mkString("")
}
// 1k primes
val primeList = Seq(2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71
, 73, 79, 83, 89, 97, 101, 103, 107, 109, 113, 127, 131, 137, 139, 149, 151, 157, 163, 167, 173
, 179, 181, 191, 193, 197, 199, 211, 223, 227, 229, 233, 239, 241, 251, 257, 263, 269, 271, 277, 281
, 283, 293, 307, 311, 313, 317, 331, 337, 347, 349, 353, 359, 367, 373, 379, 383, 389, 397, 401, 409
, 419, 421, 431, 433, 439, 443, 449, 457, 461, 463, 467, 479, 487, 491, 499, 503, 509, 521, 523, 541
, 547, 557, 563, 569, 571, 577, 587, 593, 599, 601, 607, 613, 617, 619, 631, 641, 643, 647, 653, 659
, 661, 673, 677, 683, 691, 701, 709, 719, 727, 733, 739, 743, 751, 757, 761, 769, 773, 787, 797, 809
, 811, 821, 823, 827, 829, 839, 853, 857, 859, 863, 877, 881, 883, 887, 907, 911, 919, 929, 937, 941
, 947, 953, 967, 971, 977, 983, 991, 997, 1009, 1013, 1019, 1021, 1031, 1033, 1039, 1049, 1051, 1061, 1063, 1069
, 1087, 1091, 1093, 1097, 1103, 1109, 1117, 1123, 1129, 1151, 1153, 1163, 1171, 1181, 1187, 1193, 1201, 1213, 1217, 1223
, 1229, 1231, 1237, 1249, 1259, 1277, 1279, 1283, 1289, 1291, 1297, 1301, 1303, 1307, 1319, 1321, 1327, 1361, 1367, 1373
, 1381, 1399, 1409, 1423, 1427, 1429, 1433, 1439, 1447, 1451, 1453, 1459, 1471, 1481, 1483, 1487, 1489, 1493, 1499, 1511
, 1523, 1531, 1543, 1549, 1553, 1559, 1567, 1571, 1579, 1583, 1597, 1601, 1607, 1609, 1613, 1619, 1621, 1627, 1637, 1657
, 1663, 1667, 1669, 1693, 1697, 1699, 1709, 1721, 1723, 1733, 1741, 1747, 1753, 1759, 1777, 1783, 1787, 1789, 1801, 1811
, 1823, 1831, 1847, 1861, 1867, 1871, 1873, 1877, 1879, 1889, 1901, 1907, 1913, 1931, 1933, 1949, 1951, 1973, 1979, 1987
, 1993, 1997, 1999, 2003, 2011, 2017, 2027, 2029, 2039, 2053, 2063, 2069, 2081, 2083, 2087, 2089, 2099, 2111, 2113, 2129
, 2131, 2137, 2141, 2143, 2153, 2161, 2179, 2203, 2207, 2213, 2221, 2237, 2239, 2243, 2251, 2267, 2269, 2273, 2281, 2287
, 2293, 2297, 2309, 2311, 2333, 2339, 2341, 2347, 2351, 2357, 2371, 2377, 2381, 2383, 2389, 2393, 2399, 2411, 2417, 2423
, 2437, 2441, 2447, 2459, 2467, 2473, 2477, 2503, 2521, 2531, 2539, 2543, 2549, 2551, 2557, 2579, 2591, 2593, 2609, 2617
, 2621, 2633, 2647, 2657, 2659, 2663, 2671, 2677, 2683, 2687, 2689, 2693, 2699, 2707, 2711, 2713, 2719, 2729, 2731, 2741
, 2749, 2753, 2767, 2777, 2789, 2791, 2797, 2801, 2803, 2819, 2833, 2837, 2843, 2851, 2857, 2861, 2879, 2887, 2897, 2903
, 2909, 2917, 2927, 2939, 2953, 2957, 2963, 2969, 2971, 2999, 3001, 3011, 3019, 3023, 3037, 3041, 3049, 3061, 3067, 3079
, 3083, 3089, 3109, 3119, 3121, 3137, 3163, 3167, 3169, 3181, 3187, 3191, 3203, 3209, 3217, 3221, 3229, 3251, 3253, 3257
, 3259, 3271, 3299, 3301, 3307, 3313, 3319, 3323, 3329, 3331, 3343, 3347, 3359, 3361, 3371, 3373, 3389, 3391, 3407, 3413
, 3433, 3449, 3457, 3461, 3463, 3467, 3469, 3491, 3499, 3511, 3517, 3527, 3529, 3533, 3539, 3541, 3547, 3557, 3559, 3571
, 3581, 3583, 3593, 3607, 3613, 3617, 3623, 3631, 3637, 3643, 3659, 3671, 3673, 3677, 3691, 3697, 3701, 3709, 3719, 3727
, 3733, 3739, 3761, 3767, 3769, 3779, 3793, 3797, 3803, 3821, 3823, 3833, 3847, 3851, 3853, 3863, 3877, 3881, 3889, 3907
, 3911, 3917, 3919, 3923, 3929, 3931, 3943, 3947, 3967, 3989, 4001, 4003, 4007, 4013, 4019, 4021, 4027, 4049, 4051, 4057
, 4073, 4079, 4091, 4093, 4099, 4111, 4127, 4129, 4133, 4139, 4153, 4157, 4159, 4177, 4201, 4211, 4217, 4219, 4229, 4231
, 4241, 4243, 4253, 4259, 4261, 4271, 4273, 4283, 4289, 4297, 4327, 4337, 4339, 4349, 4357, 4363, 4373, 4391, 4397, 4409
, 4421, 4423, 4441, 4447, 4451, 4457, 4463, 4481, 4483, 4493, 4507, 4513, 4517, 4519, 4523, 4547, 4549, 4561, 4567, 4583
, 4591, 4597, 4603, 4621, 4637, 4639, 4643, 4649, 4651, 4657, 4663, 4673, 4679, 4691, 4703, 4721, 4723, 4729, 4733, 4751
, 4759, 4783, 4787, 4789, 4793, 4799, 4801, 4813, 4817, 4831, 4861, 4871, 4877, 4889, 4903, 4909, 4919, 4931, 4933, 4937
, 4943, 4951, 4957, 4967, 4969, 4973, 4987, 4993, 4999, 5003, 5009, 5011, 5021, 5023, 5039, 5051, 5059, 5077, 5081, 5087
, 5099, 5101, 5107, 5113, 5119, 5147, 5153, 5167, 5171, 5179, 5189, 5197, 5209, 5227, 5231, 5233, 5237, 5261, 5273, 5279
, 5281, 5297, 5303, 5309, 5323, 5333, 5347, 5351, 5381, 5387, 5393, 5399, 5407, 5413, 5417, 5419, 5431, 5437, 5441, 5443
, 5449, 5471, 5477, 5479, 5483, 5501, 5503, 5507, 5519, 5521, 5527, 5531, 5557, 5563, 5569, 5573, 5581, 5591, 5623, 5639
, 5641, 5647, 5651, 5653, 5657, 5659, 5669, 5683, 5689, 5693, 5701, 5711, 5717, 5737, 5741, 5743, 5749, 5779, 5783, 5791
, 5801, 5807, 5813, 5821, 5827, 5839, 5843, 5849, 5851, 5857, 5861, 5867, 5869, 5879, 5881, 5897, 5903, 5923, 5927, 5939
, 5953, 5981, 5987, 6007, 6011, 6029, 6037, 6043, 6047, 6053, 6067, 6073, 6079, 6089, 6091, 6101, 6113, 6121, 6131, 6133
, 6143, 6151, 6163, 6173, 6197, 6199, 6203, 6211, 6217, 6221, 6229, 6247, 6257, 6263, 6269, 6271, 6277, 6287, 6299, 6301
, 6311, 6317, 6323, 6329, 6337, 6343, 6353, 6359, 6361, 6367, 6373, 6379, 6389, 6397, 6421, 6427, 6449, 6451, 6469, 6473
, 6481, 6491, 6521, 6529, 6547, 6551, 6553, 6563, 6569, 6571, 6577, 6581, 6599, 6607, 6619, 6637, 6653, 6659, 6661, 6673
, 6679, 6689, 6691, 6701, 6703, 6709, 6719, 6733, 6737, 6761, 6763, 6779, 6781, 6791, 6793, 6803, 6823, 6827, 6829, 6833
, 6841, 6857, 6863, 6869, 6871, 6883, 6899, 6907, 6911, 6917, 6947, 6949, 6959, 6961, 6967, 6971, 6977, 6983, 6991, 6997
, 7001, 7013, 7019, 7027, 7039, 7043, 7057, 7069, 7079, 7103, 7109, 7121, 7127, 7129, 7151, 7159, 7177, 7187, 7193, 7207
, 7211, 7213, 7219, 7229, 7237, 7243, 7247, 7253, 7283, 7297, 7307, 7309, 7321, 7331, 7333, 7349, 7351, 7369, 7393, 7411
, 7417, 7433, 7451, 7457, 7459, 7477, 7481, 7487, 7489, 7499, 7507, 7517, 7523, 7529, 7537, 7541, 7547, 7549, 7559, 7561
, 7573, 7577, 7583, 7589, 7591, 7603, 7607, 7621, 7639, 7643, 7649, 7669, 7673, 7681, 7687, 7691, 7699, 7703, 7717, 7723
, 7727, 7741, 7753, 7757, 7759, 7789, 7793, 7817, 7823, 7829, 7841, 7853, 7867, 7873, 7877, 7879, 7883, 7901, 7907, 7919)
}
As Anders Kaseorg pointed out in the comments, this code may return suboptimal (thus, wrong) results.
Results
The results for \$n\in[1,200]\$ match those from japh except for 187
, 188
, 189
, 193
.
1: 2
2: 23
3: 235
4: 2357
5: 112357
6: 113257
7: 1131725
8: 113171925
9: 1131719235
10: 113171923295
11: 113171923295
12: 1131719237295
13: 11317237294195
14: 1131723294194375
15: 113172329419437475
16: 1131723294194347537
17: 113172329419434753759
18: 2311329417434753759619
19: 231132941743475375961967
20: 2311294134347175375961967
21: 23112941343471735375961967
22: 231129413434717353759619679
23: 23112941343471735359619678379
24: 2311294134347173535961967837989
25: 23112941343471735359619678378979
26: 2310112941343471735359619678378979
27: 231010329411343471735359619678378979
28: 101031071132329417343475359619678378979
29: 101031071091132329417343475359619678378979
30: 101031071091132329417343475359619678378979
31: 101031071091131272329417343475359619678378979
32: 101031071091131272329417343475359619678378979
33: 10103107109113127137232941734347535961967838979
34: 10103107109113127137139232941734347535961967838979
35: 10103107109113127137139149232941734347535961967838979
36: 1010310710911312713713914923294151734347535961967838979
37: 1010310710911312713713914915157232941734347535961967838979
38: 1010310710911312713713914915157163232941734347535961967838979
39: 10103107109113127137139149151571631672329417343475359619798389
40: 10103107109113127137139149151571631672329417343475359619798389
41: 1010310710911312713713914915157163167173232941794347535961978389
42: 101031071091131271371391491515716316717323294179434753596181978389
43: 101031071091131271371391491515716316723294173434753596181917978389
44: 101031071091131271371391491515716316717323294179434753596181919383897
45: 10103107109113127137139149151571631671731792329418191934347535961978389
46: 10103107109113127137139149151571631671731791819193232941974347535961998389
47: 101031071091271313714915157163167173179181919321139232941974347535961998389
48: 1010310710912713137149151571631671731791819193211392232941974347535961998389
49: 1010310710912713137149151571631671731791819193211392232272941974347535961998389
50: 10103107109127131371491515716316717317918191932113922322722941974347535961998389
51: 101031071091271313714915157163167173179181919321139223322722941974347535961998389
52: 101031071091271313714915157163167173179181919321139223322722923941974347535961998389
53: 1010310710912713137149151571631671731791819193211392233227229239241974347535961998389
54: 101031071091271313714915157163167173179211392233227229239241819193251974347535961998389
55: 101031071091271313714915157163167173179211392233227229239241819193251972574347535961998389
56: 101031071091271313714915157163167173179211392233227229239241819193251972572634347535961998389
57: 101031071091271313714915157163167173179211392233227229239241819193251972572632694347535961998389
58: 101031071091271313714915157163167173179211392233227229239241819193251972572632694347535961998389
59: 1010310710912713137149151571631671731792113922332277229239241819193251972572632694347535961998389
60: 101031071091271313714915157163167173211392233227722923924179251819193257263269281974347535961998389
61: 1010310710912713137149151571631671732113922332277229239241792518191932572632692819728343475359619989
62: 10103107109127131371491515716316717321139223322772293239241792518191932572632692819728343475359619989
63: 1010307107109127131371491515716316717321139223322772293239241792518191932572632692819728343475359619989
64: 10103071071091271311371391491515716316721173223322772293239241792518191932572632692819728343475359619989
65: 10103071071091271311371491515716313916721173223322772293239241792518191932572632692819728343475359619989
66: 10103071071091271311371491515716313921167223317322772293239241792518191932572632692819728343475359619989
67: 10103071071091271311371491515716313921167223317322772293239241792518191932572632692819728343475359619989
68: 1010307107109127131137149151571631392116722331732277229323924179251819193257263269281972833743475359619989
69: 1010307107109127131137149151571631392116722331732277229323924179251819193257263269281972833743475359619989
70: 101030710710912713113714915157163139211672233173227722932392417925181919325726326928197283374347534959619989
71: 101030710710912713113714915157163139211672233173227722932392417925181919325726337269281972834743534959619989
72: 101030710710912713113714915157163139211672233173227722932392417925181919337257263472692819728349435359619989
73: 10103071071091271311371491515716313921167223317322772293372392417925181919347257263492692819728353594367619989
74: 101030710710912713113714915157163139211672233173227722932392417925181919337347257263492692819728353594367619989
75: 1010307107109127131137313914915157163211672233173227722933792392417925181919347257263492692819728353594367619989
76: 101030710710912713113731391491515716321167223317322772293379239241792518191934725726349269281972835359438367619989
77: 101030710710912713113731391491515716321167223317337922772293472392417925181919349257263535926928197283674383896199
78: 1010307107109127131137313914915157163211672233173379227722934723972417925181919349257263535926928197283674383896199
79: 101030710710912713113731391491515721163223317337922772293472397241672517925726349269281819193535928367401974383896199
80: 101030710710912713113731391491515721163223317337922772293472397241672517925726349269281819193535928367401974094383896199
81: 101030710710912713113731391491515721163223317337922772293472397241916725179257263492692818193535928367401974094383896199
82: 1010307107109127131137313914915157223317322772293379239724191634725167257263492692817928353594018193674094211974383896199
83: 1010307107109127131137313914922331515722772293379239724191634725167257263492692817353592836740181938389409421197431796199
84: 101030710710912713113731391492233151572277229323972419163472516725726349269281735359283674018193838940942119743179433796199
85: 101030710710912713113731391492233151572277229323924191634725167257263492692817353592836740181938389409421197431794337943976199
86: 1010307107109127131137313914922331515722772293239241916347251672572634926928173535928367401819383894094211974317943379443976199
87: 1010307107109127131137313914922331515722772293239241916347251672572634926928173535928367401819383894094211974317943379443974496199
88: 1010307107109127131137313914922331515722772293239241916347251672572634926928173535928367401819383894094211974317943379443974494576199
89: 10103071071091271311373139149223315157227722932392419163472516725726349269281735359283674018193838940942119743179433794439744945746199
90: 10103071071091271311373139149223315157227722932392419163251672572634726928173492835359401819367409421197431794337944397449457461994638389
91: 10103071071091271311373139149223315157227722932392419163251672572634726928173492835359401819367409421197431794337944397449457461994638389467
92: 101030710710912713113731391492233151572277229323924191632516725726347926928173492835359401819367409421197431794337944397449457461994638389467
93: 101030710710912713113731391492233151572277229323924191632516725726347926928173492835359401819367409421197431794337944397449457461994638389467487
94: 101030710710912713113731392233149151572277229323924191632516725726347926928173492835359401819367409421197431794337944397449457461994638389467487
95: 1010307107109127131137313922331491515722772293239241916325167257263479269281734928353594018193674094211974317943379443974499457461994638389467487
96: 1010307107109127131137313922331491515722772293239241916325167257263269281734792834940181935359409421197431794337944397449945746199463674674875038389
97: 1010307107109127131137313922331491515722772293239241916325167257263269281734792834940181935359409421197431794337944397449945746199463674674875038389509
98: 101030710710912713113732233139227722932392419149151572516325726326928167283479401734940942118193535943179433794439744994574619746367467487503838950952199
99: 1010307107109127131137322331392277229324191491515725163257263269281672834794017349409421181935359431794337944394499457461974636746748750383895095219952397
100: 101030710710922331127131373227722932414915157251632572632692816728347940173494094211394317943379443944994574618191935359463674674875038389509521975239754199
101: 101030710710922331127131373227722932414915157251632572632692816728347401734940942113943179433794439449945746181919353594636746748750383895095219752397541995479
102: 101030710710922331127131373227722932414915157251632572632692816728347401734940942113943179433794439449945746181919353594636746748750383895095219752397541995479557
103: 101030710710922331127131373227722932414915157251632572632692816728340173474094211394317943379443944945746181919349946353594674875036750952197523975419954795575638389
104: 101030710710922331127131373227722932414915157251632572632692816728340173474094211394317943379443944945746181919349946353594674875036750952197523975419954795575638389569
105: 101030710722331109227127722932413137325149151571632572632692816728340173474094211394317943379443944945746181919349946353594674875036750952197523975419954795575638389569
106: 1010307107223311092271277229324131373251491515716325726326928167283401734740942113943179433794439449457461819193499463535946748750367509521975239754199547955775638389569
107: 1010307107223311092271277229324131373251491515716325726326928167283401734740942113943179433794439449457461819193499463535946748750367509521975239754199547955775638389569587
108: 10103071072233110922712772293241313732514915157163257263269281672834017340942113943179433794439449457461819193474634994674875035359367509521975239754199547955775638389569587
109: 10103071072233110922712772293241313732514915157163257263269281672834017340942113943179433794439449457461819193474634994674875035359367509521975239754199547955775638389569587599
110: 1010307223311072271092293241277251313732571491515726326928163283401674094211394317343379443944945746179463474674875034995095218191935359367523975419754795577563838956958759960199
111: 1010307223311072271092293241277251313732571491515726326928163283401674094211394317343379443944945746179463474674875034995095218191935359367523975419754795577563838956958759960199607
112: 1010307223311072271092293241277251491515716325726326928167283401734094211313734317943379443944945746139463474674875034995095218191935359367523975419754795577563838956958759960199607
113: 22331101030722710722932410925127725714915157263269281632834016740942113137343173433794439449457461394634746748750349950952181919353593675239754197547955775638389569587599601996076179
114: 2233110103072271072293241092512571277263269281491515728340163409421131373431734337944394494574613946347467487503499509521675239754191819353593675479557756383895695875996019760761796199
115: 22331010307227107229324109251257126311277269281491515728340163409421131373431734337944394494574613946347467487503499509521675239754191819353593675479557756383895695875996019760761796199
116: 22331010307227107229324109251257126311269281277283401491515740942113137343173433794439449457461394634674875034750952163499523975416754795577563535936756958759960181919383896076179619764199
117: 223310103072271072293241092512571263112692812772834014915157409421131373431734433794494574613946346748750347509521634995239541675479557756353593675695875996018191938389607617961976419964397
118: 223310103072271072293241092512571263112692812772834014915157409421131373431734433794494574613946346748750347509521634995239541675475577563535936756958759960181919383896076179619764199643976479
119: 223310103072271072293241092512571263112692812772834014915157409421131373431734433794494574613946346748750347509521634995239541675475577563535695875935996018191936760761796197641996439764796538389
120: 2233101030722710722932410925125712631126928127728340149151574094211313734317344337944945746139463467487503475095216349952395416754755775635356958760181919359367607617961976419964397647965383896599
121: 22331010307227107229324109251257126311269281277283401491515740942113137343173443379449457461394634674875034750952163499523954167547557756353569587601819193593676076179641976439764796538389659966199
122: 223310103072271072293241092512571263112692812772834014915157409421131373431734433794494574613946346734748750349950952163523954167547557756353569587601819193593676076179641976439764796538389659966199
123: 2233101030722710722932410925125712631126928127728340149151574094211313734317344337944945746139463467347487503499509521635239541675475577563535695876018191935936776076179641976439764796538389659966199
124: 2233101030722710722932410925125712631126928127728340149151574094211313734317344337944945746139463467347487503499509521635239541675475577563535695876018191935936076179641976439764796536776599661996838389
125: 22331010307227107229324109251257126311269127728128340149151574094211313734317344337944945746139463467347487503499509521635239541675475577563535695876018191935936076179641976439764796536776599661996838389
126: 2233101030701072271092293241251257126311269127728128340149151574094211313734317344337944945746139463467347487503499509521635239541675475577563535695876018191935936076179641976439764796536776599661996838389
127: 223310103070107092271092293241251257126311269127728128340149151574094211313734317344337944945746139463467347487503499509521635239541675475577563535695876018191935936076179641976439764796536776599661996838389
128: 223310103070107092271092293241251257191263112691277281283401491515740942113137343173443379449457461394634673474875034995095216352395416754755775635356958760181935936076179641976439764796536776599661996838389
129: 22331010307010709227109229324125125719126311269127277281283401491515740942113137343173443379449457461394634673474875034995095216352395416754755775635356958760181935936076179641976439764796536776599661996838389
130: 223307010103227092293241072510925712631126912719128128340140942113137331491515727743173443379449457461394634673474875034995095216352395416754755775635356958760181935936076179641976439764796536776599661996838389
131: 2233070101032270922932410725109257126311269127191281283401409421131373314915157277431734433794494574613946346739487503475095216349952395416754755775635356958760181935936076179641976439764796536776599661996838389
132: 2233070101032270922932410725109257126311269127191281283401409421131373314915157277431734433794494574613946346739487503475095216349952395416754755775635356958760181935936076179641976439764796536776599661996838389
133: 223307010103227092293241072510925712631126912719128128340140942113137331443173449149457277433794613946346739487503475095215157516349952395416754755775635356958760181935936076179641976439764796536776599661996838389
134: 22330701010322709229324107251092571263112691271912812834014094211313733144317344914945727743379461394634673948750347509521515751634995239541675475575635356958757760181935936076179641976439764796536776599661996838389
135: 22330701010322709229324107251092571263112691271912812834014094211313733144317344914945727743379461394634673948750347509521515751634995239541675475575635356958757760181935936076179641976439764796536776599661996838389
136: 2233070101032270922932410725109257126311269127191281283401409421131373314431734491494572774337946139463467394875034750952151575163499523954167547557563535695875776018193593607617964197643976479653677696599661996838389
137: 22330701010322709229324107251092571263112691271912812834014094211313733144317344914945727734613946346739487433795034750952151575163499523954167547557563535695875776018193593607617964197643976479653677696599661996838389
138: 2233070101032270922932410725109257126311269127191281283401409421131373314431734491494572773461394634673948743379503475095215157516349952395416754755756353569587577601819359360761796419764397647965367787696599661996838389
139: 22330701010322709229324107251092571263112691271912812834014094211313733144317344914945727734613946346739487433795034750952151575163499523954167547557563535695875776018193593607617964197643976479765367787696599661996838389
140: 22330701010322709229324107251092571263112691271912812834014094211313733144317344914945727734613946346739487433795034750952151575163499523954167547557563535695875776018193593607617964197643976479765367787696599661996838389809
141: 223307010103227092293241072510925712631126912719128112834014094211313733144317344914945727734613946346739487433795034750952151575163499523954167547557563535695875776018193593607617964197643976479765367787696599661996838389809
142: 223307010103227092293241072510925712631126912719128112834014094211313733144317344914572773461394634673948743379503475095214952395415157516349954755756353569587577601676076179641935936439764797653677659966197876968383898098218199
143: 223070101032270922932410725109257126311269127191281128340140942113137331443173449145727734613946346739487433475034950952149952337954151575163535475575635695875776016760761796419359364396479765367765996619768383898098218199823978769
144: 223070101032270922932410725109257126311269127191281128340140942113137331443173449145727433461394634673474875034950952149952337954151575163535475575635695875773960167607617964193593643964797653677659966197683838980982181998239769827787
145: 223070101032270922924107251092571263112691271912811283401409421131373314431734491457274334613946346734748750349509521499523379541515751635354755756356958757739601676076179641935936439647976536599661976836776980982181998239782778782938389
146: 2230701010322709229241072510925712631126912719128112834014094211313733144317344914572743346139463467347487503495095214995233795415157516353547557563569587577396016760761796419359364396479765367765996619768383976980982181998239827787829389
147: 2230701010322709229241072510925712631126912719128112834014094211313733144317344914572743346139463467347487503495095214995233795415157516353547557563569587577396016760761796419359364396479765365996619768367769809821819982397827787829383985389
148: 2230701010322709229241072510925712631126912719128112834014094211313733144317344914572743346139463467347487503495095214995233795415157516353547557563569587576016760761796419359364396479765365996619768367739769809821819982398277829383985389857787
149: 2230701010322709229241072510925712631126912719128112834014094211313733144317344914572743346139463467347487503495095214995233795415157516353547557563569587576016760761796419359364396479765365966197683677397698098218199823982778293839853898577878599
150: 2230701010322709229241072510925712631126912719128112834014094211313733144317344914572743346139463467347487503495095214995233795415157516353547557563569587576016760761796419359364396479765365966197683677397698098218199823982778293839853857787859986389
151: 22307010103227092292410725109257126311269127191281128340140942113137331443173449145727433461394634673474875034950952149952337954151575163535475575635695875760167607617964193593643964797653659661976836773976980982181998239827782938398538577877859986389
152: 22307010103227092292410725109257126311269127191281128340140942113137331443173449145727433461394634673474875034950952149952337954151547515755756353569587576016359360761796419364396479765365966197683676980982167739782398277829383985385778778599863898818199
153: 22307010103227092292410725109257126311269127191281128340140942113137331443173449145727433461394634673474875034950952149952337954151547515755756353569587576016359360761796419364396479765365966197683676980982167739782398277829383853857787785998638988181998839
154: 22307010103227092292410725109257126311269127191281128340140942113137331443173449145727433461394634673474875034950952149952337954151547515755756353569587576016359360761796419364396479765365966197683676980982167739782398277829383853857785998638988181998839887787
155: 2230701010322709072292410725109257126311269127191281128340140942113137331443173449145727433461394634673474875034950952149952337954151547515755756353569587576016359360761796419364396479765365966197683676980982167739782398277829383853857785998638988181998839887787
156: 22307010103227090722924107251092571263112691127191281128340140942113137331443173449145727433461394634673474875034950952149952337954151547515755756353569587576016359360761796419364396479765365966197683676980982167739782398277829383853857785998638988181998839887787
157: 22307010103227090722924107251092571263112691127191281128340140942113137331443173449193457274334613946346734748750349509521499523379541515475155756353569587576015760761796419764396479765359365966199683676980982163823978277398293838538577859986389881816778778839887
158: 2230701010322709072292410725109257126311269112719128112834014092934211313733144317344919345727433461394634673474875034950952149952337954151547515575635356958757601576076179641976439647976535936596619968367698098216382397827739829853838577859986389881816778778839887
159: 22307010103227090722924107251092571263112691127191281128340140929342113137274314433173344919345746139463467347487503495095214995233735354151547515575635695875760157607617964197643964796535937976596619968367698098216382397827739829853838577859986389881816778778839887
160: 2230701010322709072292410725109257126311269112719128112834014092934211313727431443317334491934574613941463467347487503495095214995233735354151547515575635695875760157607617964197643964796535937976596619968367698098216382397827739829853838577859986389881816778778839887
161: 223070101032270907229241072510925712631126911271912811283401409293421131372743144331733449193457461394146346734748750349475095214995233735354151547515575635695875760157607617964197643964796535937976596619968367698098216382397827739829853838577859986389881816778778839887
162: 22307010103227090722924107251092571263112691127191281128340140929342113137274314433173344919345746139414634673474875034947509521499523373535415154751557563569535875760157607617964197643964796535937976596619968367698098216382397827739829853838577859986389881816778778839887
163: 2230701010322709072292410725109257126311269112719128112834014092934211313727431443317334491934574613941463467347487503494750952149952337353541515475155756356953587576015760761796419764396479653593797659661996768367698098216382397827739829853838577859986389881816778778839887
164: 22307010103227090722924107251092571263112691127128112834014092934211313727431443317334491457461394146346734748750349475095214995233735354151547515575635695358757601576076179641919359379643964797197653659661996768367698098216382397827739829853838577859986389881816778778839887
165: 223070101032270907229241072510925712631126911271281128340140929342113137274314433173344914574613941463467347487503494750952149952337353541515475155756356953587576015760761796419193593796439647971976536596619967683676980982163823977398277829853838577859986389881816778778839887
166: 22307010103227090722924107251092571263112691127128112834014092934211313727431443317334491457461394146346734748750349475095214995233735354151547515575635695358757601576076179641919359379643964797197653659661996768367698098216382397739827782983838538577859986389881816778778839887
167: 223070101032270907229241072510925712631126911271281128340140929342113137274314433173344914574613941463467347487503494750952149915152337353541547515575635695358757601576076179641919359379643964797197653659661996768367698098216382397739827782983838538577859986389881816778778839887
168: 2230701010322709072292410725109257126311269112712811283401409293421131372743144331733449145746139414634673474875034947509521499151523373535415475155756356953587576015760761796419193593796439647971976536596619967683676980982163823977398277829838385385778599786389881816778778839887
169: 2230701009070922710103229241072510925712631126911272728112834014092934211313733144317344914574334613941463467347487503494750952149915152337515415475575635356953587576015760761796419193593796439647971976536596619967683676980982163823977398277829838385385778599786389881816778778839887
170: 22307010090709227101310322924107251092571263112691127272811283401409293421134431373317344914574334613941463467347487503494750952149915152337515415475575635356953587576015760761796419193593796439647971976536596619967683676980982163823977398277829838385385778599786389881816778778839887
171: 22307010090709227101310191032292410725109257126311269112727281128340140929342113443137331734491457433461394146346734748750349475095214991935233751515415475575635356953587576015760761796419643964796535937971976596619967683676980982163823977398277829838385385778599786389881816778778839887
172: 22307010090709227101310191021032292410725109257126311269112727281128340140929342113443137331734491457433461394146346734748750349475095214991935233751515415475575635356953587576015760761796419643964796535937971976596619967683676980982163823977398277829838385385778599786389881816778778839887
173: 223070100907092271013101910210310722924109251257126311269112727281128340140929342113443137331734491457433461394146346734748750349475095214991935233751515415475575635356953587576015760761796419643964796535937971976596619967683676980982163823977398277829838385385778599786389881816778778839887
174: 223070100907092271013101910210310331107229241092512571263132691127272811283401409293421137334431734491457433461394146346734748750349475095214991935233751515415475575635356953587576015760761796419643964796535937971976596619967683676980982163823977398277829838385385778599786389881816778778839887
175: 223070100907092271013101910210310331103922924107251092571263132691127272811283401409293421137334431734491457433461394146346734748750349475095214991935233751515415475575635356953587576015760761796419643964796535937971976596619967683676980982163823977398277829838385385778599786389881816778778839887
176: 223070100907092271013101910210310331103922924104910725109257126313269112727281128340140929342113733443173449414574334613946346734748750349475095214991935233751515415475575635356953587576015760761796419643964796535937971976596619967683676980982163823977398277829838385385778599786389881816778778839887
177: 223070100907092271013101910210310331103922924104910510725109257126313269112727281128340140929342113733443173449414574334613946346734748750349475095214991935233751515415475575635356953587576015760761796419643964796535937971976596619967683676980982163823977398277829838385385778599786389881816778778839887
178: 223070100907092271013101910210310331103922924104910510610725109257126313269112727281128340140929342113733443173449414574334613946346734748750349475095214991935233751515415475575635356953587576015760761796419643964796535937971976596619967683676980982163823977398277829838385385778599786389881816778778839887
179: 223070100907092271013101910210310331103922924104910510610631325107257109263269112727281128340140929342113733443173449414574334613946346734748750349475095214991935233751515415475575635356953587576015760761796419643964796535937971976596619967683676980982163823977398277829838385385778599786389881816778778839887
180: 223070100907092271013101910210310331103922924104910510610631325106911072571092632692811272728340140929342113733443173449414574334613946346734748750349475095214991935233751515415475575635356953587576015760761796419643964796535937971976596619967683676980982163823977398277829838385385778599786389881816778778839887
181: 223070100907092271013101910210310331103922924104910510610631325106911072571087263269281092834012727409293421137334431734494145743346139463467347487503494750952149919352337515154154755756353569535875760157607617964196439647965359379719765966199676836769809821638239773982778298383853857785997863898811816778778839887
182: 2230701009070922710131019102103103311039229241049105106106313251069107257108726326928109112727283401409293421137334431734494145743346139463467347487503494750952149919352337515154154755756353569535875760157607617964196439647965359379719765966199676836769809821638239773982778298383853857785997863898811816778778839887
183: 2230701009070922710131019102103103311039229241049105106106313251069107257108726326928109110932834012727409293421137334431734494145743346139463467347487503494750952149919352337515154154755756353569535875760157607617964196439647965359379719765966199676836769809821638239773982778298383853857785997863898811816778778839887
184: 2230701009070922710131019102103103311039229241049105106106313251069107257108726326928109110932834010971929340941272742113733443173449457433461394634673474875034947509521499193523375151541547557563535695358757601576076179641976439647965359379765966199676836769809821638239773982778298383853857785997863898811816778778839887
185: 2230701009070922710131019102103103311039229241049105106106313251069107257108726326928109110932834010971929340941272742113733443173449457433461394634673474875034947509521499193523375151541547557563535695358757601576076179641976439647965359379765966199676836769809821638239773982778298383853857785997863898811816778778839887
186: 2230701009070922710131019102103103311039229241049105106106313251069107257108726326928109110932834010971929340941272742113733443173449457433461394634673474875034947509521499193523375151541547557563535695358757601576076179641976439647965359379765966199676836769809821638239773982778298383853857785997863898811816778778839887
187: 223070100907092271013101910210310331103922924104910510610631325106910725710872632692810911093283401097192934094127274211173344317433449457461373463467347487503494750952149919352337515154157547557563535695358757601635937960761796419764396479765365966199676836769809821811397739823982778298383853857785997863898816778778839887
188: 223070100907092271013101910210310331103922924104910510610631325106910725710872632692810911093283401097192934094111727421123344317334494574337346137463467347487503494750952127514991935235354151575475575635695358757601635937960761796419764396479765365966199676836769809821811397739823982778298383853857785997863898816778778839887
189: 1009070101307092232271019102103103310491051061063110392292410691072510872571091109326326928109719283401117274092934211233443131733449411294574337346137463467347487503494750952127514991935235354151575475575635695358757601635937960761796419764396479765365966199676836769809821811397739823982778298383853857785997863898816778778839887
190: 10090701013070922322710191021031033104910510610631103922924106910725108725710911093263269281097192834011172740929342112334431317334494112945743373461374634673474875034947509521139523535412751499193547557563569535875760157607617964197643964796535937976596619967683676980982163823977398277829838385385778599786389881151816778778839887
191: 100907010130709101910210310331049105106106311039223227106910722924108725109110932571097192632692811172728340112334092934211294113137334431734494574337461394634673474875034947509521151153523535412751499193547557563569535875760157607617964197643964796535937976596619967683676980982163823977398277829838385385778599786389881816778778839887
192: 1009070101307091019102103103310491051061063110392232271069107229241087251091109325710971926326928111727283401123340929342112941131373344317344945743374613946346734748750349475095211511535235354116354751275575635695358757601499193593796076179641976439647976536596619967683676980982157739778239827782983838538578599786389881816778778839887
193: 1009070101307092232271019102103103310491051061063110392292410691072510872571091109326326928109711171928340112334092934211294113137274317334433734494574613946346734748750349475095211511535235354127514991935475575635695358757601576076179641976439647965359379765966199676836769809821811638239773982778298383853857785997863898816778778839887
194: 10090701013070922322710191021031033104910510610631103922924106910725108725710911093263269281097111719283401123340929342112941131372743173344337344945746139463467347487503494750952115115352353541163547512755756356953587576014991935937960761796419764396479765365966199676836769809821577397782398277829838385385785997863898811816778778839887
195: 100907010130709101910210310331049105106106311039223227106910722924108725109110932571097111719263269281123283401129293409411313727421151153443173344945743346139463467347487503494750952116352337353541181187512754755756356953587576014991935937960761796419764396479765365966199676836769809821577397782398277829838385385785997863898816778778839887
196: 100907010130709101910210310331049105106106310691072231103922710872292410911093251097111711232571926326928112928340113137274092934211511534431733449411634574334613946346734748750349475095211811875119352337353541275475575635695358757601499196076179641976439647965359379765966199676836769809821577397782398277829838385385785997863898816778778839887
197: 100907010130709101910210310331049105106106310691072231103922710872292410911093251097111711232571926326928112928340113137274092934211511534431733449411634574334613946346734748750349475095211811875119352337353541201275475575635695358757601499196076179641976439647965359379765966199676836769809821577397782398277829838385385785997863898816778778839887
198: 1009070101307091019102103103310491051061063106910710872231103922710911093229241097111711232511292571926326928113132834011511534092934211634431733449411811872743345746137346346734748750349475095211935233751201213953535412754755756356958757601499196076179641976439647965359379765966199676836769809821577397782398277829838385385785997863898816778778839887
199: 10090701013070910191021031033104910510610631069107108710911039223110932271097111711232292411292511313257192632692811511532834011634092934211811872743173344334494119345746137346346734748750349475095212012139523375121754127547557563535695358757601499196076179641976439647965359379765966199676836769809821577397782398277829838385385785997863898816778778839887
200: 100907010130709101910210310331049105106106310691071087109109311039110971117112322711292292411313251151153257192632692811632834011811872740929342119344317334494120121373457433461394634673474875034947509521217512233752353541275475575635695358757601499196076179641976439647965359379765966199676836769809821577397782398277829838385385785997863898816778778839887
201: 1009070101307091019102103103310491051061063106910710871091093110391109711171123112922711313241151153251163257192632692811811872728340120121373340929342119344317344941217433457461394634673474875034947509521223375122952353541275475575635695358757601499196076179641976439647965359379765966199676836769809821577397782398277829838385385785997863898816778778839887
202: 1009070101307091019102103103310491051061063106910710871091093110391109711171123112922711313241151153251163257192632692811811872728340120121373340929342119344317344941217433457461394634673474875034947509521223375122952353541275475575635695358757601499196076179641976439647965359379765966199676836769809821577397782398277829838385385785997863898816778778839887
203: 10090701013070910191021031033104910510610631069107108710910931103911097111711231129113132271151153241163251181187257192632692812012137272834012173340929342119344317433449412233734574613946346734748750349475095212295235354123751275475575635695358757601499196076179641976439647965359379765966199676836769809821577397782398277829838385385785997863898816778778839887
204: 100907010130709101910210310331049105106106310691071087109109311039110971117112311291131151153132271163241181187251201213725719263269281217272834012233409293421193443173344941229457433734613946346734748750349475095212375124952353541275475575635695358757601499196076179641976439647965359379765966199676836769809821577397782398277829838385385785997863898816778778839887
205: 1009070101307091019102103103310491051061063106910710871091093110391109711171123112911311511531163132271181187241201213725121725719263269281223283401229293409412372742119344317334494574334613946346734748750349475095212495233735354125937953547512755756356958757601499196076179641976439647976535965966199676836769809821577397782398277829838385385785997863898816778778839887
206: 1009070101307091019102103103310491051061063106910710871091093110391109711171123112911311511531163132271181187241201213725121725719263269281223283401229293409412372742119344317334494574334613946346734748750349475095212495233735354125937953547512773955756356958757601499196076179641976439647976535965966199676836769809821577823977827829838385385785997863898816778778839887
207: 10090701013070910191021031033104910510610631069107108710910931103911097111711231129113115115311631181187227120121313724121725122325719263269281229283401237274092934211934431733449412494574334613946346734748750349475095212593735233795353541277395475127955756356958757601499196076179641976439647976535965966199676836769809821577823977827829838385385785997863898816778778839887
208: 100907010130709101910210310331049105106106310691071087109109311039110971117112311291131151153116311811871201213137227121724122325122925719263269281237274012492934094125934211937334431734494574334613946346734748750349475095212773952337953535412795475128355756356958757601499196076179641976439647976535965966199676836769809821577823977827829838385385785997863898816778778839887
209: 1009070101307091019102103103310491051061063106910710871091093110391109711171123112911311511531163118118712012131217227122313724122925123725719263269281249293401259340941277274211937334431734494574334613946346734748750349475095212795233795353541283547512895575635695875760149919607617964197643964797653596596619967683676980982157739778239827829838385385785997863898816778778839887
210: 1009070101307091019102103103310491051061063106910710871091093110391109711171123112911311511531163118118712012131217227122313724122925123725719263269281249293401259340941277274211937334431734494574334613946346734748750349475095212795233795353541283547512895575635695875760149919607617964197643964797653596596619967683676980982157739778239827829838385385785997863898816778778839887
211: 10090701013070910191021031033104910510610631069107108710910931103911097111711231129113115115311631181187120121312171223137227122924123725124925719263269281259293401277274094127942119344317334494574334613946346734748750349475095212835233735354128953547512975575635695875760149919607617964197643964796535937976596619967683676980982157739778239827829838385385785997863898816778778839887
212: 100907010130101910210310330709104910510610631069107108710910931103911097111711231129113115115311631181187120121312171223227122924123725124925719263269281259293401277274094127942119344313733173449457433461394634673474875034947509521283523375128953535412975475575635695875760149919607617964197643964796535937976596619967683676980982157739778239827829838385385785997863898816778778839887
213: 10090701013010191021031033070910491051061063106910710871091093110391109711171123112911303115115311631181187120121312171223227122924123725124925719263269281259293401277274094127942119344313733173449457433461394634673474875034947509521283523375128953535412975475575635695875760149919607617964197643964796535937976596619967683676980982157739778239827829838385385785997863898816778778839887
214: 1009070101301019102103103310491051061063106910709108710910931103911097111711231129113031151153116311811871201213071217122312292271237241249251259257192632692812772740127929340941283421193443131733449457433461373463467347487503494750952128952337512975413953535475575635695875760149919607617964197643964796535937976596619967683676980982157739778239827829838385385785997863898816778778839887
215: 100907010130101910210310331049105106106310691070910871091093110391109711171123112911303115115311631181187120121307121712231229227123724124925125925719263131926928127727401279293409412834211934431733449457433461373463467347487503494750952128952337512975413953535475575635695875760149919607617964197643964796535937976596619967683676980982157739778239827829838385385785997863898816778778839887
216: 100907010130101910210310331049105106106310691070910871091093110391109711171123112911303115115311631181187120121307121712231229227123724124925125925719263131926928127727401279293409412834211934431733449457433461321289463467347487503494750952129751373523375413953535475575635695875760149919607617964197643964796535937976596619967683676980982157739778239827829838385385785997863898816778778839887
217: 1009070101301019102103103310491051061063106910709108710910931103911097111711231129113031151153116311811871201213071217122312291237227124924125925127725719263131926928127929340128340941289421193443173344945727433461321297463467347487503494750952132751373523375413953535475575635695875760149919607617964197643964796535937976596619967683676980982157739778239827829838385385785997863898816778778839887
218: 1009070101301019102103103310491051061063106910709108710910931103911097111711231129113031151153116311811871201213071217122312291237227124924125925127725719263131926928127929340128340941289421193443173344945727433461297463467347487503494750952132132751361373523375413953535475575635695875760149919607617964197643964796535937976596619967683676980982157739778239827829838385385785997863898816778778839887
219: 100907010130101910210310331049105106106310691070910871091093110391109711171123112911303115115311631181187120121307121712231229123712492271259241277251279257192631319269281283401289293409412972742119344317334494574334613213274634673474875034947509521361367513735233754139535354755756356958757601499196076179641976439647965359379765966199676838098215769823977398278298383853857785997863898816778778839887
220: 100907010130101910210310331049105106106310691070910871091093110391109711171123112911303115115311631181187120121307121712231229123712492271259241277251279257192631319269281283401289293409412972742119344317334494574334613213274634673474875034947509521361367513735233754139535354755756356958757601499196076179641976439647965359379765966199676838098215769823977398278298383853857785997863898816778778839887
221: 100907010130101910210310331049105106106310691070910871091093110391109711171123112911303115115311631181187120121307121712231229123712492271259241277251279257192631319269281283401289293409412972742119344317334494574334613213274634673474875034947509521361367513735233754138139535354755756356958757601499196076179641976439647965359379765966199676838098215769823977398278298383853857785997863898816778778839887
222: 1009070101301019102103103310491051061063106910709108710910931103911097111711231129113031151153116311811871201213071217122312291237124922712592412772512792571926313192692812834012892934094129727421193443173344945743346132132746346734748750349475095213613675137352337541381399195353547557563569587576014996076179641976439647965359379765966199676838098215769823977398278298383853857785997863898816778778839887
n=11
trivial since you just have to verify thatn=10
also satisfies the new condition. I'd also argue that hard-coding only helps untiln=17
, since no numbers are known beyond that point as far as I've been able to find out. \$\endgroup\$[1,22,234,2356,112356,113256,1131724,113171924,1131719234,113171923294,113171923294,1131719237294]
and starting a search from each \$\endgroup\$