Manufactoria: generate the slowest possible accepting program Write a Manufactoria program that will accept the empty input tape.  But don't do it quickly!  I mean, write the program quickly, but don't let it run quickly.  The slower the program, the better, as long as it terminates eventually.  The example program below takes 3:51 (the "total time" reported by the simulator).



http://pleasingfungus.com/Manufactoria/?lvl=36&amp;code=g12:5f3;r9:8f1;p12:9f3;c13:9f0;r11:9f0;r10:9f0;r9:9f1;b11:8f0;b10:8f1;r9:7f2;c10:7f2;c11:7f2;c12:7f3;q12:8f3;y13:8f2;y14:8f2;y15:8f1;y15:7f0;y14:7f0;y13:7f0;g12:6f3;&amp;ctm=Slow_Accepter!;Generate_the_slowest_possible_accepting_machine;:;7;3;0;

Your program starts with the empty tape.  It must doodle around a bit, but eventually reach the output square.  You may leave data on the tape if you wish.  The slowest program on the 7x7 Manufactoria board wins!

Your right arrow key is your friend, it speeds up the simulator.

Bonus points for crashing the simulator!
~1023 iterations ~1015 iterations ~108 iterations



http://pleasingfungus.com/Manufactoria/?lvl=32&amp;code=g9:7f2;b12:8f2;p13:8f5;p11:8f3;r14:8f0;q11:10f3;q13:7f1;y13:9f1;r10:10f1;c12:9f2;c9:9f2;i11:9f7;i10:9f4;c9:8f3;i10:8f2;c14:9f0;c15:9f0;c15:8f3;c15:7f3;c14:7f2;g12:7f0;c11:7f3;c10:7f2;q9:6f7;r10:6f1;r9:5f3;c11:6f0;r10:5f2;r11:5f1;r9:4f3;r10:4f0;r11:4f0;y12:5f2;y13:5f2;y14:5f3;y14:6f0;y13:6f0;y12:6f0;&amp;ctm=Slow_Accepter!;Generate_the_slowest_possible_accepting_machine;:;7;3;0;

The machine is basically an odometer running in base three, using the red, blue and yellow symbols to stand for the digits 0, 1, and 2 respectively. The green symbol is used to mark the end of the number. At the start, the tape is initialized with 49 red symbols. This is done by the parts in the top three rows of the machine. The bottom four rows handle the task of incrementing the number in a loop. On each iteration, the two branch cells on left-hand side work out how to apply the increment to current number, and then the branch cells on the right-hand side copy the remaining, unaffected digits.

Previously I've tried to estimate the machine's running time, were it allowed to run to completion, but at this level it makes more sense to just go by the number of iterations. Roughly speaking, it takes about a minute to complete one iteration -- but even if it took a second that would only decrease the running time by a single order of magnitude.