Author Archive Mel


C#: Regular Expressions

I’ve decided to document what little knowledge I have on using Regular Expressions in C#. Nothing grand, just a list of formats, special characters and usage.

Control Characters:

Character Matches
. Any character but the newline (\n)
$ Characters at the end of a string
^ Characters at the beginning of a string. Also used in conjunction with ‘[]’ to specify “not.”
+ One or more of the specified characters
* Zero or more of the specified characters
? Zero or One of the specified characters
\ Used to escape special characters as well as signify special character sets
( ) Used to specify a collection of characters to match
[ ] Used to specify a set of single characters or ranges to match
{ } Used to specify how many times to match a given character(s)
| Used as a logical OR. Allows one or more expressions to be selected for a match

Special Character Sets:

Character Matches
\w Any word character. Same as [A-Za-z0-9_]
\W Any non-word character. Same as [^A-Za-z0-9_]
\s Any whitespace character. Same as [ \t\v]
\S Any non-whitespace character. Same as [^ \t\v]
\d Any digit. Same as [0-9]
\D Any non digit. Same as [^0-9]

Read More


Spore, suprisingly entertaining

So about a week ago my wonderful wife purchased me the latest video game title to splash onto the market, Spore. Although the game was announced over a year ago as the next big simulation franchise from the creative genius of Will Wright, and seemed to be receiving the praises from many a person I know as well as some good scores from online review sites, I admit I had my reservations.

Nevertheless I acquired it (by legal means this time, which is unusual for me). I was hesitant to just install it on my computers due to some discussions I’ve read concerning its use of nasty, nasty DRM software such as SecuROM. I’ve also read ill-reports of EA’s new method of controlling their software by limiting the number of installations possible from a single product key. This made me curious if there was an alternative.

So I did a little looking around and sure enough there was already a pirated image of the install disk that supposedly came without the DRM and without the install cap. This I downloaded and used to install on my gaming rig and laptop, being sure to include EA’s download manager so that I wouldn’t have go through the pain of manually keeping the game up to date and so that I could fully enjoy the benefits of Spore’s use of online shared content.

After a brief amount of setup and configuration I created a new game and entered the world as a small, single-celled organism equipped with a beak, a flagellum, and a pair of eyes. I admit the eyes were kinda silly, but they served to introduce me to the unique, almost cartoony, universe of spore. I quickly progressed through the cell stage, followed by the creature stage and arrived at the tribal stage with a feeling that I was finally getting the handle on this game; after all I was at the top of the food chain and was able to send any wobbly legged or googly eyed creature Maxis could throw at me running for their lives. Read More


First Post

So at the reluctant support of my ever-loving wife I’ve decided to cut a small chunk out of my already busy schedule to play with my own blog.

I’ve never really had the desire to catalog my thoughts, ideas and discoveries online before. In fact my first attempt at blogging was a terrible and dismal failure, never making it past the first 10 yard line. I tried to figure out what it was about in High School but didn’t make it very far.

But now that I’ve grown and learned a few things I feel I’m ready for a place to record the ever increasing flow of ideas and discoveries that I deem worthwhile, if for nothing more than to have something I can refer to later.

As a young father, an aspiring software engineer and a humble genius (is that an oxymoron?), I hope I can publish something worth writing, and maybe…. just maybe, something worth reading.