World’s Strangest

Your source for the strangest things around!
Ads

Literary Javascript

Twitter developeshakespearer and book nerd Angus Croll wondered what famous authors would do with javascript. His gives examples from his imagination for four great writers: Ernest Hemingway, Andre Breton, Roberto Bolano, and William Shakespeare. Here’s how the Bard might write code:

function theSeriesOfFIBONACCI(theSize) {

  //a CALCKULATION in two acts.
  //employ’ng the humourous logick of JAVA-SCRIPTE

  //Dramatis Personae
  var theResult; //an ARRAY to contain THE NUMBERS
  var theCounter; //a NUMBER, serv’nt to the FOR LOOP

  //ACT I: in which a ZERO is added for INITIATION

  //[ENTER: theResult]

  //Upon the noble list bestow a zero
  var theResult = [0];

That’s just Act One. See Act Two and the other authors at Fat XXX. Link -via Metafilter

Post Metadata

Date
August 7th, 2012

Author
Stranger to the World

Category



Leave a Reply