March 13, 2009

Works in a Row

by Nick Montfort · , 8:33 am

Works, Nick Montfort

In preparing for my reading at MIT yesterday, I put together a page listing my various works of literary and computational art, collaborative, translated or adapted, and individually created. You should notice the new addition to the main page of nickm.com if you happen to visit.

The list includes some new pieces: Taroko Gorge, a poetry generator written originally in Python, presented here in my port to JavaScript, and ppg256-2, the second of my 256-character poetry generators written in Perl. You can see the former running on its Web page; the latter can be copied and pasted onto the command line of systems with Perl installed (that’s Mac OS X and Linux, by default) or consult the full instructions.

I’ve also put up eight large PNG images documenting Unready.net, a site Josh Kellar and I contrived with the help of the U.S. government back in 2003. The project was of a particular historical moment, which is our excuse for letting our domain registration lapse so that a cybersquatter could acquire the domain.

If you’re just interested in ppg256-2, here it is:

perl -le 'sub p{split/,/,pop;$_[rand@_]}{$_=p("sw,-aw,&w,saw".", "x$l);s//p("aw,w")/e;s// /g;$_="\n\nthe s\n"if!$l;s/s/ws/;s/a/p("a,the,to,of")/e;s/w/p("b,ch,f,gr,k,p,sh,s,sk,sp,tw")."i".p("ll,n,t")/eg;s/(b|p|f)i/$1.p("a,i")/e;print;$l=0if$l++>6+rand 9;sleep 1;redo}'

3 Responses to “Works in a Row”


  1. Black Says:

    Nick, try the “pre” tag instead of the “code” tag. I think it works.

  2. Nick Montfort Says:

    It sort of does. Problem is that this program then appears as a single line, running over the sidebar on the right. I’ll just keep the link to my site; it’s less of a mess.

  3. Nick Montfort Says:

    This discussion here was occasioned by my complaints about how hard it is to put code into a WordPress post – complaints I have now deleted. It looks like the trick to including code without using “pre,” and without having quote marks “educated” into smart quotes, is to replace each single quote with " and each double quotes with '.

Leave a Reply

Powered by WordPress