Code Birthday Cake [pic]

Jeremy Bray —  April 11, 2011 — 3 Comments

Just when I think I couldn’t possibly find any geekier cakes than what I normally post, I came across this awesome code cake.  Any programmer is likely to love this cake, especially if they like to write code in C/C++.  While I may not be fluent in C/C++, I have enough programming experience to know exactly what is happening here.  For those who aren’t fluent in code, this code is basically taking the birthdate of somebody named Tim and figuring out how old he has turned and it prints out a Happy Birthday message for him.  If it isn’t his birthday, it prints out a message saying it isn’t his birthday.

Pass this along to all of your programmer friends!  Better yet, if you have any programmer friends, make an awesome code cake like this for them!

 

Code Birthday Cake

Code Birthday Cake

[via ForeverGeek]

Enhanced by Zemanta
  • Stephen

    Obviously the programmer failed to consider edge cases. It’ll be hilarious when this code gets used on the kid’s “111st, 112nd, and 113rd” birthday.

  • http://www.globalgeeknews.com pcnerd37

    This is why you should always test your code for bugs before putting it on a birthday cake.

  • varmfskii

    Wouldn’t it be far more serious that he never allocates the space that *timeinfo points at.