Are programming contests stretching it a bit too far?

Recently I have been trying to get some experience at solving some algorithm intensive problems by taking part in online programming contests.

The problems are no doubt very interesting and there is lot to learn from them. I have myself learned a lot about new algorithms and different ways of problem solving.

But I have some critical observations about these contests as well. In one of the recent problems which I was solving, I managed to get the correct implementation, but it used to all ways exceed the execution time limit. My implementation was not very unoptimized, it was a very simple implementation of the solution and very readable. I tried multiple iterations but did not manage to satisfy the execution time limit.

Out of curiosity I looked at some of the correct submissions, and found that all of them had implemented a very specific solution, which involved inlining lot of operations, and resulted in very unreadable code. I felt that the tester of the solution had reverse engineered using this solution and then set the time limits.

This I feel is a very wrong way of writing programs. Any experienced software engineer will tell you that the best program is the one which produces the right result and does so keeping the code simple. Simple enough so that people other than the author can also understand the code. This is also mentioned in Eric Raymond’s 17 Unix Rules, Rule of Clarity.

Advertisement

Broke my laptop :(

One of the worst things that can happen to a person who loves dismantling and putting things back is that once you put something back together, it does not work. And this is what exactly happened to me last week.

I had opened my laptop thinking that I would clean the CPU fan. I opened the laptop and managed to reach till the point of removing the keyboard. But reaching the fan seemed like a huge task. So in favour of time I put the laptop back together thinking I will do mu exercise on a weekend. This time when I put the laptop together it worked in an instant.

Couple of days later when I again opened the laptop I went till the point of removing the screen assembly. This time when I put the laptop back together, it did not boot :(.

I tried multiple things, from replacing the battery to reassembling it, but nothing worked.

I gave up hope and now the laptop is lying useless. I bought a hard disc case and put the laptop hard disc into that.

Spending money on software and services

Past couple of months I have been spending money on software and services. Which seems to be a really good trend, given that I am also in software business.

I have purchased a windows phone developer license, renewed my webhosting contract, bought windows 8 pro, and donated to Wikipedia.

Overall I see that if I am doing it then others will also be doing it, which is a very healthy sign.

Go software!!! Wooo hooo!!!! (in case you did not get the woo hoo part, watch this 🙂 )

AT&T is dumb or what?

I stay in India where we don’t have AT&T and I still know that they are dumb. I recently visited US on a business trip and took a AT&T sim there. I used it for 10 days, without any issues, and came back to India. Once I came back I switched to Airtel. Some days later I tried switching on Internet connection sharing on my Windows Phone 7.5 phone, it is a HTC Radar, and guess what came up, I got an error message that to enable tethering I need to goto att.com/mywireless or call 611. Now, I was not even on AT&T network, so how dumb are AT&T to screw up my phone like this with no option to fix it.

To get my phone back to old state I had to reset my phone. I lost all apps and data. But I got all my contacts back, thanks to Windows live.

Now again, how dumb is AT&T. After reading on internet I understood that they charge $30-$45 to enable tethering, that is also so weird. I would somehow never go for a plan like that. Here in India, I am free to do what ever I want with my phone.

Review: Asus X45A Windows 8 Laptop

After using a 2.5 kg laptop for a while, I wanted a small (max 14" screen), cheap (30K Rs. or less), light weight laptop (2Kg or less) with more battery life (at least 3 hours). My primary requirements were net surfing, writing documents, watching movies and listening to music. I had not finalized on the price, but anything below 30k rupees was ok.

I visited Best Buy and started scouting laptops which fitted my need. Some of the models which I considered some HP, Lenovo and Asus models. (the Sony models were all expensive). At the end I zeroed down on Asus X45A, and got it for $300 (16K Rupees).

Asus X45A comes with Windows 8, 4GB RAM, 320 GB HDD, DVD RW, HDMI, VGA out, 14" screen (1366×768), 2 USB ports (one 2.0 and one 3.0), wireless n, HD webcam, and card reader. After using it for one month I an extremely satisfied. The battery life is awesome, lasts for almost 5 hours when just surfing or writing documents. The screen contrasts are really nice. The dual core Celeron processor is more than adequate, and does not heat too much. And it a very light weight laptop so it is a breeze to carry it around. Compared to my other laptop HP 8560w, this is very handy.

For a $300 laptop it is really worth it. I totally recommend it for anyone looking for a cheap laptop for data processing and light weight needs.

But be aware that this is a budget model, so you will get a plastic body and not metal, the keyboard is not backlit, and only 2 USB ports.

Another reason why Facebook is not a replacement for your own website

I recently came across this post at InfoWars, where it mentions how Facebook has been censoring posts. What was even more interesting was the notice which Facebook sent to one of the editors stating “Be careful making about making political statements on facebook, Facebook is about building relationships not a platform for your political viewpoint. Don’t antagonize your base. Be careful and congnizat (sic) of what you are preaching.”

Hmm… very interesting and clear precise objective given by Facebook. So use Facebook only for timepass, don’t talk or discuss any thing serious over there.

Best option, just get a domain and host your own blog, and express what ever you wish to, till it is legal :). If it is illegal than the hosting server will itself pull down your website.

Restored some old posts

I finally restored some old posts from my blog. Due to this many of the below posts have today’s date. The restoration was a manual process of copy past of text from the MySQL file of the old wordpress blog. Going forward I will use the wordpress blog’s backup/restore functionality.

First donation to Wikipedia

Today I did my first donation to Wikipedia. It surely won’t be the last. Pasting the mail which I received after making the donation. The nicest bit was the example of a Bangalore kid using Wikipedia to learn computer programming, so true.

Dear KULDEEP,

Thank you for donating to the Wikimedia Foundation. You are wonderful!

It’s easy to ignore our fundraising banners, and I’m really glad you didn’t. This is how Wikipedia pays its bills — people like you giving us money, so we can keep the site freely available for everyone around the world.

People tell me they donate to Wikipedia because they find it useful, and they trust it because even though it’s not perfect, they know it’s written for them. Wikipedia isn’t meant to advance somebody’s PR agenda or push a particular ideology, or to persuade you to believe something that’s not true. We aim to tell the truth, and we can do that because of you. The fact that you fund the site keeps us independent and able to deliver what you need and want from Wikipedia. Exactly as it should be.

You should know: your donation isn’t just covering your own costs. The average donor is paying for his or her own use of Wikipedia, plus the costs of hundreds of other people. Your donation keeps Wikipedia available for an ambitious kid in Bangalore who’s teaching herself computer programming. A middle-aged homemaker in Vienna who’s just been diagnosed with Parkinson’s disease. A novelist researching 1850s Britain. A 10-year-old in San Salvador who’s just discovered Carl Sagan.

On behalf of those people, and the half-billion other readers of Wikipedia and its sister sites and projects, I thank you for joining us in our effort to make the sum of all human knowledge available for everyone. Your donation makes the world a better place. Thank you.

Most people don’t know Wikipedia’s run by a non-profit. Please consider sharing this e-mail with a few of your friends to encourage them to donate too. And if you’re interested, you should try adding some new information to Wikipedia. If you see a typo or other small mistake, please fix it, and if you find something missing, please add it. There are resources here that can help you get started. Don’t worry about making a mistake: that’s normal when people first start editing and if it happens, other Wikipedians will be happy to fix it for you.

I appreciate your trust in us, and I promise you we’ll use your money well.

Thanks,

Sue

Sue Gardner

Executive Director,

Wikimedia Foundation

https://donate.wikimedia.org

 

HTC Radar Windows Phone has in built maps/navigation!!!!

This is called bad marketing, i.e. HTC Phones have a application called Locations which is the inbuilt navigation software provided in HTC phones and till now I did not know that. I bought a HTC Radar Windows Phone 6 months ago, and one of the sore points was that it did not have Google Maps. Nokia provided an alternative by providing Nokia Drive application. But with HTC phone I was stuck with using apps like Bingle Maps and gMaps. I was in fact going to develop my own Windows Phone application which would provide navigation using Google Maps.

Today while browsing web I found that HTC Locations is the inbuilt app in HTC phones for navigation. It is not that I have not run the application earlier, but then the UI is not that friendly and there is a similar named app called HTC Footprints which is pathetic, so I never launched this app as well.

Anyways, now I have started the download of India maps on the application. It is a 500+ MB download and will take some time. Hopefully this should be a good alternative to using Bingle Maps or gMaps.