Archive for November, 2007
The best Regular Expression HOWTO
Yep, the best resource for learning RegEx (Regular Expressions) you will ever find on the Internet would be this one:
Seriously, all I needed was an hour in the evening!
Look and Say Sequence
Have no idea why it took near 2 hours for me to write this. Maybe it was the stupid OOP paper I gave today, I’ve been in a bad mood after writing a 40-pager and yet feeling unsatisfactory about it.
So back to the post’s topic: The Look and Say Sequence, which I found today while solving the level 10 of The Python Challenge, is a very odd sequence of numbers which are formed by counting and spelling out the digits sequentially.
The series looks like the following:
1 11 21 1211 111221 and so on …
How this is formed:
See the first digit 1. Spell it as One One (One in quantity that is). This is the general idea.
Thus:
1 - One One: 11
11 - Two One(s): 21
21 - One Two and One One: 1211
1211 - One One, One Two and Two One(s): 111221
And on and on and on …
And now, for the Python Code.
( Took me over 80 minutes with lots of scrapping and frustration to write. Bad day
)
Managing Tag and Tags
This new Tags feature in WordPress 2.3 is confusing me. While Categories are linked as URL/tag/name, the tags are linked as URL/tags/name. And it makes NO difference at all.
What is it all about anyway?
An old yet complex Programming Puzzle
Found this today while browsing del.icio.us.
Visit: The Python Challenge
(Actually its not necessary you should use Python just cause its named so. Its a regular programming puzzle and you should do just fine with any modern language such as PHP or Java as well. C/C++ might be a bit tedious for use here.)
The good thing about this kind of a challenge is that you never ever would encounter a dead end. Its all possible and you probably know how too, but the answer always depends on how you implement your program to solve things for you. Awesome way to learn and practice code!
Am currently on level 5, having just begun. There are a total of 33 levels currently.
Note: If you are solving it, please refrain from posting spoilers here. Defeats the purpose of the entire ‘programming puzzle‘ if you post code, etc. You may post tips though, that’d be helpful, or at maximum, the basic under-lying algorithm required to crack it.
Enjoy! ![]()
New theme - The Journalist
Finally put in a new theme “The Journalist” by Lucian Marin after months of Blue-K2. This theme was recently featured on WordPress.com and is fantastic at its simplicity and minimalism!
I had to modify a bit of the CSS to help support the switch-over from the colorful Blue-K2 I had here earlier (The colors being those “Download” or “Favorite” boxes you’ve seen around, perhaps.)
Also converted a few images to Grayscale and added them for a little more eye gloss than the default theme had. Hope you like this theme, cause I find it pretty readable and wide.
Post any problems, comments on what you feel is not good and other things if you have the time. ![]()