Hello, Globe

Monday 25 April 2016, 4:45 pm   ////  

On Saturday, the 400th anniversary of Shakespeare’s death (and, happy birthday, too, Will), I delivered to Twitter, via post-haste dispatch, the following four Commodore 64 BASIC programs, versions of the famous “Hello world” program:

400 ? chr$(147)"hello world":for a=1 to 500:next:? chr$(19)"brave":new:rem #c64

400 ? chr$(144)chr$(79)chr$(84)"hello world":rem #c64

400 ? "hello world"chr$(4^3+(2b or not 2b)):rem #c64

400 for a=0to255:? chr$(147)spc(a)"(QRQ) hello world":next:? chr$(147):rem #c64

Type ’em in to a for-real Commodore 64 or to this Web-based emulator here. No special characters are involved, so entering these programs should be easy; lowercase letters will appear capitalized and the few capital ones will appear as graphical symbols.

Let me know what you think … and if you see the relationship to four of Shakespeare’s plays.

2 Comments »

  1. Does ‘new’ clear the program in memory? Also is ‘Brave New World’ the ref for that first one? A quick google indicates BNW had a lot of Shakespeare quotes in it … not something I recalled but it’s been a while.

    Comment by josh g. — 2016-04-27 @ 9:13 pm
  2. It does! And, yes! The phrase “brave new world” is from a Shakespeare play … one of many such phrases used to title books.

    Comment by Nick Montfort — 2016-04-27 @ 9:58 pm

RSS feed for comments on this post. TrackBack URI

Leave a comment

This work is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 3.0 Unported License.
(c) 2017 Post Position | Barecity theme