Shakespeare and programming

A great playwright and poet once wrote in his play Hamlet (and that great poet and playwright of course is none other than Shakespeare)Ā  the following question from act three, scene one:

To be or not to be, that is the question;

Putting it into a more geeky format I have the following translation:

2B OR NOT 2B

Which sort of turns the question into a logical statement. Tidying it up a little further and noting the unary and binary operators in the statement, as well as the operator precedence, and further clarifying its (geeky) nature I have:

0x2B OR (NOT 0x2B)

And so I arrive at an answer to the question in Hamlet’s soliloquy:

0x2B OR (NOT 0x2B) = 0xFF

The answer turns out to be pretty simple and not so philosophical and deep! šŸ˜€ If you don’t know why my answer to the famous question is 0xFF, keep on guessing! šŸ˜€

(I’m feeling geekier than usual tonight, so there you go)

Advertisements

Tags: , , ,

3 Responses to “Shakespeare and programming”

  1. Mark Says:

    Actually, it’s 0xFFFFFFFF if you have a 32bit machine, or 0xFFFFFFFFFFFFFFFF if you have a 64 bit machine šŸ™‚

  2. hoope Says:

    lol.. good try .. šŸ™‚

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s


%d bloggers like this: