Discovered the “Code Golf” in StackExchange from the people I follow in twitter (for the #codechallenge hashtag).
The question to generate the StackOverflow logo in code was particularly interesting to me and naturally I wanted to try generating the logo using C# (GDI+ code). Because nobody had a C# solution listed there, I also put the code there as an answer (Look for the answer titled “C#/GDI+”)
I initially recreated the logo in GDI+ without a for loop (every rectangle had a hardcoded value for its locations and size). Using that approach, its possible to recreate the logo almost identical to the original. But I was not happy with doing it that way. Read the rest of this entry »
The year 2012 is here. The year that some groups claim will be the last year for the planet and its life as we know it. There were many such occasions in the past too (for example, the year 2000). But, here we are… still living and breathing. Read the rest of this entry »
Despite the craze over great photos and photography in general, I managed to live with only a 3.2 megapixel mobile phone camera (I still do).
A DSLR camera has always been in my “wish list”, though nobody cared gifting me one
– just kidding.
I was helping a friend of a friend with a .NET software, that required photos to be directly transferred to a PC as soon as they are captured. As far as I know, digital cameras go into a “USB mode” that makes them mass storage devices, just like ordinary USB thumb drives. Read the rest of this entry »
Anybody who visits my blog can scan through the publish dates of the posts and know that I am not a frequent poster.
According to SEO experts, updating blog content regularly will effect the web traffic positively. So for a “rare” poster like me, seeing “Views per day: 10” in the WordPress analytics everyday is not new, and I am not serious about web traffic volume as I am (still) only a hobbyist blogger. Read the rest of this entry »
Got startled and woke up to the wild vibration and tone of my mobile phone’s alarm at 5am in the morning, stumbling in the darkness and quickly stopping the alarm, I notice 3 new text messages. Relaxing again, resting my head on the pillow, I assume they would be just some facebook alerts.
Then I muster up some energy and sit up. Deciding to go about my usual daily duties, I open the 1st message to read, which is a CNN news alert: “Google hinted today that they are making moves to get rid of Internet Explorer 6 for good, CNN”! What? wow, I thought. And I open the 2nd message…
Ok, so you don’t have to own a BlackBerry to enjoy “Push” email: Email that is actively transferred (pushed) to the device as it arrives. It doesn’t even have to be a Smartphone.
The longest, annular (like a ring) Solar Eclipse of the millennium happened today (15th January 2010).
When the annular eclipse was at its peak in the region from where I was watching it (Nugegoda, Sri Lanka), I saw some peculiar shadows on the ground. It occurred to me only after several seconds that they are caused by the Solar Eclipse! Read the rest of this entry »
It’s that time of the year again… when the whole world (or at least the countries that use the standard Gregorian Calendar) commemorates the birth of Jesus Christ. Read the rest of this entry »
Do you see any strange dots and/or arrows in the Visual Studio code editor and have no idea how you turned them on? (check the screen-shot)
If you ever generated scripts using SQL Server 2005 using Management Studio by right-clicking on table names, and tried executing it in SQL Server 2000 (using Query Analyzer), you would have encountered this problem… The Query Analyzer would report syntax errors. Read the rest of this entry »