Additionally, kids with a dog or cat at home "tended to need fewer courses of antibiotics than children without such contacts," the researchers wrote. Also, "both the weekly amount of contact with dogs and cats and the average yearly amount of contact were associated with decreased respiratory infectious disease morbidity."
"Our findings support the theory that during the first year of life, animal contacts are important, possibly leading to better resistance to infectious respiratory illnesses during childhood," the scientists concluded.
Some people are more allergic to pets than others, so having a dog or cat in those cases wouldn't be recommended. Most people, however, should benefit from pet ownership.
The question now is, how do pets achieve the health-promoting feat? My guess is that it's a form of homeopathy, wherein exposure to something builds resistance in the individual.
It's also fun to think that nature/the powers that be simply want to bring kids and pets together. The study didn't even get into the mental health benefits of pet ownership, which you can read more about here. Dogs additionally motivate people to exercise. That perk goes far beyond childhood.