From: bau@cs.cornell.edu (David Bau) Date: Tue, 27 Oct 92 14:43:15 -0500 Subject: big-printer-maze.ps I have two new postscript maze submissions. The first, this file, is intended to replace the file misc/printer-maze.ps. Please call this file big-printer-maze.ps If you have a postscript printer, this is a slick way to generate mazes. Just send this postscript file to your printer, and it will randomly generate a maze and print it out. You can modify the numbers appearing at the beginning of the file to change the appearance of the maze or to change the page size or the number of pages taken up by the maze. You can even get the printer to print out an answer page. If you are having trouble getting mazes out of the file, you have to make sure that the file begins with the %! line, and have to send the file directly to your printer, either by usinging Adobe's free program SendPS, in the info-mac archives or the System 7 Laserwriter utility. Send me a postcard if you like it! David Bau bau@cs.cornell.edu }----- cut here -----{ %! true % Big labyrinth for postscript printers, Copyright 1992 by David Bau 1 612 % horiz pages, pts/page % This file is free puzzleware :) Please pass it 1 792 % vert pages, pts/page % on only for free, and keep my original comments 18 % page margin (overlap) % intact. And if you like it or improve it, send 12 % corridor size % me a postcard from your home town! 2 % linecap style 0.2 % wall thickness % 777 South Avenue; Weston, MA 02193; USA 0.5 % path thickness % bau@cs.cornell.edu 86 dict begin/J{bind def}bind def/A{def}J/`{0 1}J/r{for}J/m{pop}J/.{exch}/H{. A }/q{bitshift}/a{rand}/:{/v H/X H/W X 2 z A/S 0 v 2 z B A/Q S array A ` S R{p 15 x}r 1 1 W 2 y{= 2 x S ! z p 8 x}r W W S ! !{= 1 x R W z p 4 x}r Q Q ? 0 0 O W 1 O S W O S 1 O/C a X i d a v i d B A U 31 x{U W z e U ! e or U d e or U R e or{{ 4/D a 5 i A " D ne{U g z w 15 Y{u}t}t}h/_ 1 D q A/~ 1 D 2 xor q A _ C K/M C g z A Q M ? w ~ xor g neg W z d 5 q or x M}{C U w -5 q R ! z}o = w -5 q 0 Y{u}t/C H }h m/P * d A 0 P B $/N v * y A X N B $/s 0 P B A/E X N B d A/C s A/D 0 A{/_ U w A{3 1 0 I 0 2 1 I 1 4 2 I 2 8 3 I}h " U U w 31 and g d W z 5 q or x/C C g z A C E Y{u}t/D D d 4 i A}h}/p{Q .}/u{exit}/d{1 z}/y{sub}/t{if}/B{W mul z}/R{1 y}/U{Q C}/Y{eq}/x{put}/w{get}/i{mod}/S{W mul z}/o{ifelse}/h{loop}/l{idiv}/z{add}/-{and 0}/|{stroke}/'{moveto}/*{a v 7 l i}/K{p ? w 4 3 roll xor x}/={dup p}/!{W y}/?{2 copy}/I{D Y{_ - Y{m u}{/D H}o}{m m}o}/c{D Y{/g H}{m}o}/${dup 1 . K 4 . d K}/e{w 15 Y}/O{y 0 x}/+{Q k j B w}/&{C W i .5 y C W l .5 y}/G{setlinewidth}/V{` v d{/j H F ` X d{/k H + 2 - ne{n not{k R j #}t}{n{k R j ^}t}o}r |}r ` X d{/k H F ` v d {/j H + 1 - ne{n not{k j R #}t}{n{k j R ^}t}o}r |}r}/"{1 0 c W 1 c -1 2 c 0 ! 3 c}/b{dup f Z f mul y 2 div}/#{'/n true A}/,{/C s A & '{E/C U w -5 q R ! C z A & ? lineto | ' C Y{u}t}h}/F{false/n H}/da{div y 2 div z}/dt{translate}/ds{div dup scale}/dd{? ml z . mb z dt f f scale lc setlinecap wt G V}/^{lineto F}/ly{H L y L y}/Z{div cvi}` 50{m J}r/pt H/wt H/lc H/f H/L ly/hh H/ph H hh ph mul/; ly/ww H /pw H ww pw mul/T H T b/ml H ; b/mb H T f Z ; f Z : 0 hh neg ; neg d{0 ww neg T neg d{L L dt dd showpage m}r m}r{}{ph pw gt{L ww T ph da L dt 1 ph ds}{L L hh ; pw da dt 1 pw ds}o 0 0 dd m m pt G , showpage}o end