This has always bugged (rotten ((hey, I did it twice!)) pun) me. Bananas. You buy them. Eat one or two. And by day three there are all these little gnats flying around. This doesn't seem to bother anyone I know. Not the gnats per se. You just squish them, move on. But where did they come from?!
I don't think it is very likely that the buggers enter the house from outside because they posses a supernatural power that allows them to somehow know a piece of fruit is starting to go "over" ripe in there. It just makes sense that the eggs are already on the bananas when you buy them. They hatch, voila'! This bears repeating. The eggs are already ON the bananas when you buy them. And not just sometimes, but ALL THE TIME. I've never not had a banana and not had gnats for a week afterwards; meaning everytime I buy bananas I get the little bugs. That really disturbs me. I mean think of the odds...I've been alive a long time (cough cough), bought and eaten a lot of bananas but never can I remember gnat-free episode.
I did some googling and found a few people who suggest washing the fruit when you first get it home, thus washing away the eggs (thus proving my theory). Most,however, go into great detail about making elaborate traps (involving beer, juice, homemade cones, boiling water...) to get rid of the pests.
I think I'd much rather sit down and eat a half dozen gnats than think about a colony of eggs hatching, and larvae-ing on the fruit I just bought and handled and have sitting on my kitchen counter.