I came across this top 50 best jobs list a while ago. I was very surprised to see my job, software engineer, as many of my friends’ jobs, is on the top of the list. I got the hard copy of magazine today and confirmed this. I have quite a few friends who are college professors (ranked 2nd), I am happy for them too.
There are a few factors in deciding the rank: the number of job openings, the salary growth, flexibility and creativity of the work, barrier of entry, etc. I believe the software engineer position is ranked high because of its projected salary growth (46%) in next 10 years. Not sure if this could materialize for US programmers with the outsourcing to India and China.