2 Mile Run in Pseudocode

require ("Nike+");

function run (@tempo, @distance) {
var @m; // instantiate mile variable

// create new Nike+ instance
@np = new Nike+();
@np.setDistance(@distance);
@np.setPlaylist("Hella Sound Running");

// loop through each mile in distance
for (@m; @m <= @distance; @m++) {
@t = getTerrain();
if (@t["elevation"]["upcoming"] > @t["elevation"]["current"]) {
John.stride.length--;
}
John.legs.ambulate();
}
}

function getTerrain () {
var @surface;
var @elevation = array ();
// returns concrete, asphalt, gravel, dirt
@surface = eval(Earth.loc.surface);
// assess current elevation
@elevation["current"] = Earth.loc().topography;
// assess upcoming elevation
@elevation["upcoming"] = Earth.loc("10 feet ahead").topography;
return array(@surface, @elevation)
}

$(John.ready(function(@) {
// put on some clothes
John.apparel("Asics", "Racevine shirt", "shorts");
// hydrate a little
John.drink("water");
// run, bitches!
John.run("165", "2");
});
I dare you to out-dork this post. I mean, how are you going to beat poorly-written procedural pseudocode? The gauntlet, my running blogging friends, has been thrown down.

Total Weight: -12lbs*
* Yeah, big weight change since last Friday. Sunday and Monday were gluttonous: IHOP, Gamine, Chinese food and Philly cheesesteak. Bad and off-plan, but this'll drop back down just as quick as it went up.

5 Brilliant Remarks:

  1. You, my friend, are the MASTER. I laughed pretty hard... //run bitches!

    And, Ambulate!? You have some crazy function names. :)

  2. I love it. Of course, I'm one of the dorks who went and read every line.

  3. Alicia A said...

    I don't know what's worse- tthat you wrote in code or that I followed each and every line without issue. < *dork>Ali< /*dork>

  4. [html]
    [!DOCTYPE html PUBLIC]
    [title]Comment[/title]
    [body]
    This post made my brainpan hurt. [p]
    But ... HAR!
    [/p]
    [/body]
    [/html]

  5. thanks for stopping by my site! I will most definitely be back :)