Answer:
There is a surplus population of cats and dogs. No one is willing to take care of them, so to keep them from running wild in human-populated areas (which can be a health hazard because of diseases like rabies), they are euthanized. This is considered the most painless way to end their lives. You can do your part to prevent euthanization by spaying or neutering your pets, and by adopting from shelters like the Humane Society instead of purchasing your pet from breeders.