The one that has completed projects on his own. If neither one of them could demonstrate such a thing, the one that seemed more intelligent.
Also, the difference between 10 years and 20 years of experience, I think, is less than the difference between, say, 5 years and 10 years... I think the wage curve would imply most people agree with me here. In the case of someone with 2.5 years of personal experience and 2.5 years of professional experience, vs. 5 years of professional experience, if all else were equal (which is to say, either neither has completed a project they can show me, or they both have, and they seem about as smart, and they are willing to work for the same wage) it's pretty much a toss-up in my mind. If the guy with 5 years work seems more professional, I might go with him, just 'cause I lack professionalism, and it can be really useful sometimes.
But, the thing is, it's usually not equal. the guy with 2.5 years paid experience and 2.5 years hobby experience, in my experience, is likely to work for only slightly more than someone with only 2.5 years of professional experience.
So, given the choice between hiring the person with 5 years paid experience at market rate for a person with 5 years paid experience, and the person with 2.5 years paid experience and 2.5 years hobby experience at the market rate for someone with 2.5 years of experience, I'll easily take the latter. (at least in my experience, pay goes up /fast/ in the early parts of your career.)
Why? I really don't believe that's true, at least in the US. This says nothing about requiring that they program outside of business hours. As long as they aren't putting any sort of demands on their non-work time, I don't see the problem in using someone's passion as a factor in hiring. There's only a problem if they place some demands on non-work time or fire you for it.
> [...] which one would you pick ?
Depends on the job. If constant learning of new tech is integral to the job, I might go for less experience. (Again, this doesn't imply not paying them for their time.)
That was the exact question the OP posted, the title is 'No, I Wouldn't Hire a Programmer That Has No Interest in Programming Outside of Business Hours', and framed like that it is illegal.
The way you frame it it is legal, relevant work experience, whether gathered inside or outside of work time before the employment commences is a good thing to pick up on that passion.
But given two applicants, one that has 20 years of experience during work time and none that he cares to report about during the interview outside of work time and one that has 10, 5 years working in his spare time and 5 years during employment which one would you pick ?
The latter has 'passion' according to the OP, the former is a clockwatcher.