Because to be really good at programming takes an almost obsessive devotion to honing your craft at a young age, and girls are far too social to spend their summers in front of a computer in the basement.
I would argue that that isn't the case at all. While I was one of those little boys who spent way too much time in front of a computer and video games as a kid, that is mostly NOT the case amongst my coworkers (I'm a software engineer at Google). Most seemed to pick it up in college when they chose it as a major, and didn't have much or any experience with computer science before then. I would argue the main difference between those who succeed here and those who don't is intelligence, a hunger to learn (rather than just tinker), and a good work ethic.
I don't mean to say that being locked away in your room as a child programming, etc, would hurt in any way. Again, that was mostly me as a child. I just mean that what matters most is an understanding of computer science and software engineering principles (Data Structures, Machine Learning, etc) not can you bang out a few thousand lines of code in a few hours. I never do that at work. I think it's more important to develop as a child the ability to learn, process, and make connections between ideas, and that can happen via learning in any field.
Just my 2 cents for what they are worth.