Daniel Martin
7/8/2006 5:37:00 PM
Daniel Martin <martin@snowplow.org> writes:
> Having now changed to that method, (change one letter and recalculate)
> I'm now getting sub-minute times reasonably frequently. I'm still not
> getting anywhere near the times quoted, but I'm going to try some
> other optimizations to see what I can get.
Indeed:
$ time ruby /cygdrive/c/Temp/sallowsgram2.rb
30607
Daniel Martin's sallowsgram program produced a sentence with eight
'a's, one 'b', three 'c's, five 'd's, thirty-eight 'e's, eight 'f's,
seven 'g's, ten 'h's, si xteen 'i's, one 'j', one 'k', four 'l's, four
'm's, twenty-two 'n's, fourteen 'o's, three 'p's, one 'q', thirteen
'r's, twenty-nine 's's, twenty-five 't's, five 'u's, seven 'v's, eight
'w's, two 'x's, five 'y's, and one 'z'.
real 0m7.685s
user 0m7.468s
sys 0m0.046s
On the other hand, using this as a prefix:
"The program from martin@snowplow.org produced a sentence with "
yielded no result after over two hours and 33 million iterations over
all 26 letters.
I'm thinking that there may be times when the algorithm wanders off
and gets stuck in a region where there are no solutions. I'm going to
try a tweak to let it get out of cages like that.
(Of course, there may actually be no solution with that prefix.
Writing a program to prove that, though, is more than just a weekend
project.)