A function that returns insanity

A function that returns insanity

Playing around with a bit of pseudo-code today (loosely based off C#).  It’s a bit of a nerd-play off of the concept of “Build. Fly. Crash. Repeat.

 

I originally started out with a function that returns “happiness”.  Here is what it looked like:

A function that returns happiness

This is a function named “everythingcpo.com” that returns “happiness”.  It’s essentially an endless loop that says while it’s a heli, a plane, or a multirotor that you have, it will loop through build, then fly, then crash, then back to build, then fly, then crash, then back to build, then…okay, I am sure you get the point. 😉

 

Someone then suggested that I probably should have made “build, fly, and crash” into methods as well…and that makes sense, since in reality they are collections of different steps. I decided to make that change, and then realized that I am not sure that this function returns happiness as much as it returns insanity. I changed that. I think this endless loop results in insanity. Super fun, and expensive, insanity! ; )

Here is the new version:

A function that returns insanity

 

Bye!