I prefer assault riffles, when going up against a horde, the shotgun is too inaccurate at long distances and takes too long to reload.
We also have to talk about sustainability. I know most people talk about the biggest problem with guns is that you will run out of bullets, but that effects all weapons, swords can only cut through a handful of zombies before becoming blunt, and trust me from experience that if your chainsaw runs out of gas, you'd have a better chance of throwing it away then expecting to refill it. As running with a chainsaw is not easy and refilling is rather time consuming.
Some people have in the past suggested the crossbow and the bow and arrow, as its easier to collect used arrows, then used bullets, but again accuracy and fire rate become an issue.
This is why I would go with an semi-auto AR such as the M16.
That said, shotguns have an advantage in spread, if someone doesn't know how to use a gun, then a sawed-off shotgun is the best choice, so I guess it does come down to experience.