Extension Methods

There are 2 entries for the tag Extension Methods
Math.Min and Math.Max are Backwards

Every time I need to prevent a value from going under a minimum or going over a maximum, I have to stop and think about how to use the Math API.  If I want to supply a max value, I need to use Math.Min; and conversely, if I want to supply a min value, I need to use Math.Max. Given int value = 5, if I want to ensure that my value has a minimum of 10, I need to call: Math.Max(value, 10). Given int value = 500, if I want to ensure that my value has a...

posted @ Tuesday, February 3, 2009 12:43 AM | Feedback (3)

I don't like magic anymore

Growing up, I always liked magic.  I actually spent a significant portion of my childhood earnings at a local magic shop in Milford, Ohio.  I remember vying for the really fancy tricks, but I always had to settle for the simpler, cheaper tricks.  I have always been excited to see magic performed and try to figure out how it might be done.  When The Illusionist came out on DVD, I watched and loved it.  Then I saw The Prestige, which blew The Illusionist away.  (If you haven't seen The Prestige, go add it to your Netflix list right now, it's...

posted @ Monday, June 2, 2008 10:14 PM | Feedback (1)