Virtually all the comments on here are missing a key point: everything they say is true, but it was true twenty years ago when there were a lot more women going into computer science than are now, though still far fewer than men.
I think what's changed is that many other professions have openeed up to women. When I started work as a programmer, almost all doctors, lawyers, etc. were male. Computer programming, though, was much closer to a pure meritocracy - no one cared about your chromosomes so long as you could code. So it was a good avenue for intelligent women to pursue. Now, they have plenty of alternatives and, as others have noted, women seem to be more inclined than men to pursue more people-oriented professions, like doctors and lawyers, when those options are open to them.
When speculation has done its worst, two plus two still equals four. -- S. Johnson