Fun with Pseudocode

A long time ago, I saw this on

A programmer started to cuss
Because getting to sleep was a fuss
As he lay there in bed
Looping ’round in his head
was: while(!asleep()) sheep++

It inspired me to name my blog foreach(bill) paywith(skill), which was intended to “pseudocodify,” if you will, the expression, “Skills to pay the bills.”

Recently I asked the audience of if they knew of any others. Here’s a few of my favorites, some of them with my slight modifications.


question = 2*b || !(2*b)

Working for the man:

class Employee
	long hours;
	short lunch;
	byte pay;

A Star Wars reference to Yoda, who says, “Try not. Do… or do not. There is no try.”:

do() || !do()
// try()

A classic:

while(!(succeed = try());

From Futurama, in BASIC:

10 SIN

Ah, to be a kid again.

if (happy && know(it)) hands.clap();


  1. Sunny said

    Great to have you back!

  2. […] WordPress – Fun with Pseudocode […]

RSS feed for comments on this post · TrackBack URI

Leave a Reply

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

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

Google+ photo

You are commenting using your Google+ 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 )

Connecting to %s

%d bloggers like this: