The Perfect Logic

Three days of super sunny weather and two following rainy days;

A super cold morning and a sunny, shiny evening;

One normal morning and snow in the afternoon.

I was wondering what algorithm does the Washington-Weather-Lady use to determine what she is going to do next. Must be something crappy like this.

public JustVoid DetermineWeather(bool useCrappyWeather)

 //Lets do something different once in blue moon.
 bool onceInBlueMoon = false;
 int today = GetTodaysDate();

 //Set some defaults
 string morning = “Bad”;
 string afternoon = “Worse”;
 string evening = “Better than worse”;
 string night = “Worst”;

 string yesterday = “You Know it rained”;
 string today = “Only this logic knows”;
 string tomorrow = “You Never Know”;


         Print(“What were you thinking? This is Washington.”) 

        //Never mind what’s requested, it’s always crappy.
       useCrappyWeather = true;

 //Lets fix blue moon
 //Some logic that almost always returns negative
 if(today == “End of the world”
       || today != “start of the year”
       || today == “Alien sighting day”
       || today == “Belongs to Cretaceous period?”
       || today != “holiday”)
   onceInBlueMoon = true;   

 //We never want the weather to be the same as yesterday’s.
 //Just pretend to reverse the weather (Business/Marketing idea to get more people live here)
 //Read Environmental (literally) variable
 yesterday = ReadEnvVar(“YESTERDAY”);//Worst average of yesterday’s

            case “DISGUSTING”:
                    morning = “Just the same”;

            case “CLOUDY”:
                    morning = “Keep it Rolling”;

           case “Raining”:
                    morning = “Can we make it worse?”;

          case “Sunny”:
                   morning = “You are just lying”;

  //Double check weather was good
  MessageBox.Show (“Was weather yesterday Sunny? Select an option”, “No”,”No”)
  if(LoadNewResponse() == “No”)
     morning = “I told you..”; 
     //Something is really odd here.
     //Anyway, check for blue moon
        morning = “OKAY. FINE. Enjoy while it lasts.. Grrrrr..”   
      morning = “(Grinning)..Sorry folks…”;


 case “Really Cant Say”:
          morning = “What makes you think you will have stable weather today?”;


 //Alright, lets set the rest of the day

 if(morning ! = Sunny)
        afternoon = Aggravate(morning);
        evening = MakeWorse(afternoon);
        night = JustGoToBedWhyDoYouCare(“never mind”);
    for (today = 0; today < next 10 days; today ++)
          Apply(“Its pay back time”);         

 //we are almost done. Lets calculate the average of today and set the environmental variable
 yesterday = GetWorseOfToday();
 //There is nothing fair in this world my dear..Just reset
 yesterday = “Super crappy”; //enjoy….          


6 thoughts on “The Perfect Logic

  1. Haha 🙂 🙂

    That was really geeeky!! Do you not do enough coding at work to get bored of this stuff.. or are you one of those who actually enjoy what they do 😛

    1. Thanks Piyu..I guess I have to say its the second one..Just got so used to it. that expressing in the syntax seems easier than in words…omg…what has this s/w done to me? 🙂

  2. Hilarious and ingenious! Loved it 🙂 And you work in MS! I bow to thee. It’s a dream to me. Oh and the header image is awesome!
    PS: why don’t you leave a link? It’d be easier to get to your space 🙂

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 )

Twitter picture

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

Facebook photo

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

Google+ photo

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

Connecting to %s