Friday, May 25, 2012

Friendship Algorithm in Java

UPDATE: Source code fixed and updated below.

UPDATE: Currently trying to nail down a problem with the loopcounter at the end of the code. I will update the source here as soon as it is fixed.

For Geek Pride Day (May 25)/ 42 Day (25+05+12), a super double geek-out! I took the Friendship Algorithm from the second season of The Big Bang Theory and spent about an hour converting it into Java code in Eclipse. The result is an extremely convoluted but functional bag of Java loops that accepts input of answers to the original flow chart's questions and goes down the proper path for the answers. Full source code below.

Friday, March 9, 2012

My Entirely Improvised Story that I Told to Victoria (Or, On The Origin of Pugs)

Tonight I was putting Victoria to bed, and as usual had to improvise a final short story after the main one(s) to finally get her to bed. Tonight I improvised based on what was around and told the following story (which I have slightly improved for this post):

Once upon a time there lived a beautiful princess named Victoria. Now Victoria was lonely in her castle because she didn't have a prince yet, so she decided to get a dog. When she caught 2 dogs, she found them to be too rowdy and not cuddly enough, so she changed them into the fun kind of dog she was thinking of using a bit of her magic. She made them have short, push-in snotty faces, short legs and body, a fat tummy, and a curly tail. She named the new kind of dog the "pug", because it rhymed with "hug", which is what she wanted to do to them. WHen she finally did meet her prince, Harry The 3rd And A Half, he loved the dogs as well, and spread them throughout the land. Thus from then on everyone loved pugs. THE END.