I don't think programming is something you become good at simply by doing your 9-5. I've worked with a lot of 9-5'ers and they're rarely the best or most rewarded developers.
What I'm certainly NOT saying is that you should work _all_ hours, in fact I will say exactly the opposite, don't, but, do be willing (if you're able) to finish solving a problem before you call it a day. For your sake, not for your employer's sake. I prefer to finish my work day on the last "problem solved". It leaves you in a much better position to leave your work at work, than when you have a problem you didn't solve and which will bug you until you solve it. If you find a problem is going to take more than "minutes" to solve, accept that its a problem for another day and try to leave it at that.
To further elaborate on my first statement, so it isn't misinterpreted again;
Do it because you enjoy it, and you _want_ to do more of it outside of work; even if you don't do, but, even IF you don't, you can visit conferences, meetups, hack-spaces, various other <insert-tech-or-language>-con, you'll meet cool people, learn about things you didn't know and perhaps teach other something. If you can make it "a way of life", contrary to ck425, do spend _some_ of your free time working on programming tasks, find something different from your work, for example, contribute some time to an OSS project you like (for e.g. I use and like to contribute to Home Assistant) or some other project you enjoy using, where you'll interact with the skilled people behind those projects.
To be clear, that I'm not disagreeing with ck425, just that he (and probably others) might misinterpret what I'm saying as "you should spend all your time programming or else you'll suck": Do all of this, only after you done the other things you enjoy doing more.