Saturday, October 11, 2008

Is ‘Divide and Conquer Algorithm’ a human instinct?

Last Friday I was with my son at a restaurant, I was browsing the menu, when I thought I will give my son a quick problem, and see how far he reaches in solving it. The menu had 5 pages, each page had about 20 items.

I asked my son if he could find the ‘cheapest’ and the ‘costliest’ items in the entire menu.

My son is 6 years old, and does some very basic mathematics at the school, such as arranging numbers in ascending and descending orders, simple single-digit additions and subtractions, etc.

I was amazed to find that, my son quickly found the cheapest item on page #1, then the cheapest item on page #2, chose the lesser of two ( MIN(page#1,page#2) ), and then recursively did that for pages 3, 4 and 5. And gave me the cheapest item on the menu (Rs. 6). He then did the same for costliest item, he found the costliest item on page #1, then the costliest item on page #2, chose the higher of two ( MAX(page#1,page#2) ), and gave the answer (Rs. 95). [We were at a Udipi restaurant, so things are not that costly here.]

I never taught him the ‘divide and conquer algorithm’, in fact I have never taught him any algorithm.

Is ‘Divide and Conquer Algorithm’ a human instinct? Does it come without learning?


Labels: , , ,

Monday, October 06, 2008

5 Hacks for Startup Hiring in India

Here are some thoughts on hiring for a Startup in India. My experience with hiring in India for the last fifteen years, in one word, has been – “Awesome” ! In Pune I have met some of the best Programmers and Designers in the world and work with many of them. There are some of most hardworking, smart and knowledgeable individuals, who love to crank code (read an interesting post here, under the “People” section). I love working with the great guys at Komli!

Hiring in India is different than hiring in other parts of the world. The following thoughts are written for an employer in mind, especially a startup employer. These thoughts are in a random order, and based on personal experiences. Please don’t equate my consistent use of ‘he/him’ with a gender bias.

1. “Offer acceptance is not equal to JOINING”

This is something you learn the hard way. It is very difficult to believe that a candidate talks so nicely, and accepts your job offer, only to NOT show up on the joining date. This is a shocker, which takes several days to recover from. If the candidate is good he calls up/e-mails you a few days in advance, telling you that he cannot join. Many will not inform you, and simply won’t show up on the joining date.

My recent experience – “a senior managerial candidate, who was relocating from the USA to India, accepted the offer after several negotiations that went on for weeks. He was very happy and I was very happy, that we have a deal. The day he was supposed to land in Pune, and join after a few hours of landing – he didn’t show up. I patiently waited until the evening, and next morning. Emailed him, and found out that instead of flying into Pune, he landed into Bangalore, and joined another large company yesterday. How nice.”

Accept the fact – a hire is only a “probability” until the day he shows up. This probability increases as the date of joining comes near. An offer acceptance on e-mail, or in hardcopy are still probabilities of joining.

The way I would handle this is – a) don’t count on a hire until he joins, b) always plan for backups – no hiring is complete until the last guy joins, c) keep calling the candidate every few days, to find out if he is going to join – if he tells that he is not joining, it’s better to know that early on, rather than on the last date, and d) if the numbers are large – over-hire, to compensate for the probability.

2. “The Resume”

I have found that many resumes have inaccurate information in them. You can actually build a “probability-framework” on what percentage of a resume is true – based on some of the key parameters of the resume – such as skill-set (Java, PHP, RoR, ASP.NET, C/C++, C#, etc). Try that, it works.

The way I handle this is – talk to the candidate, find out what he has done. Correlate that with his resume. Most of the times they match.

Another interesting parameter is the – “keyword density”. My personal experience has been that the higher the keyword density, the more likely is that the candidate is bogus. You cannot learn – all of “C, C++, Java, PHP, MySQL, Oracle, OLTP, Apache, Tomcat, RoR” in 2 years :-)

3. “The Sourcing”

Sourcing of resumes has a major impact on the success rate. I think it is very important to access the success rate of each of the source of resumes – direct, referral, recruiters, newspapers, online portals, etc. You may be surprised to know that there may be a difference of 10x in the conversion rates of each of these sources – so you should focus on the source that has the highest conversion rate.

For startups referrals work the best. Keep your employees happy, so that they find more friends who want to become happy!

4. “The Interview”

A few things at the top of my head are following:
Do initial screenings before you go too deep into technical discussion. If the candidate is not good, let’s find out in the first ten minutes of discussion, so that you save time on both sides. One important thing in my mind is – ask questions about your most recent problem that your company is facing, find out if he can solve that problem or not. Even if a guy can solve the most complex algorithm problems, or he can do the most optimal data structure design – can he solve your current (or past two-three) problems? Make sure you factor that into the overall decision. Don’t compare the candidate to yourself – “he is not like me; I can do it better than him”. It is very difficult to find a guy better that yourself, don’t try that :-)

5. “The Timing”

Try to keep “good” interviews at the top of the day, during mornings. You are in the office at 9AM, if the candidate doesn’t show up, or doesn’t pickup the phone – that does very bad things to your day. It’s a difficult thing to do, but I try and keep most interviews at the later part of the day.

Well, that’s all I have for now. There are many more things, but I wanted to keep it simple.

Got any more ideas, send me a message on facebook or Twitter?

Labels: , , , , , ,