Only if you outnumber the enemy 3-1.
Recently I attacked an AI's capitol with two Axemen, an archer, and a chariot on it with only Axes and Swords. Oh - and it was on a hill, and had walls.
I had I believe, 9 total units, and that included two Bowmen (Archers with a bonus against melee) and a Spearman, the rest a mix of Swords and Axes. I wasn't sure if I could win - but it turned out to be a cinch, since one of my Swords won with 9% odds, and then the next one won with 16% odds.
Simply awesome.*
Anyway, while those things are great, you can't plan for them, and if you try to base your strategy on it, you'll lose most of the time. So only attack with 20-30% odds of success if you have more units to throw into the fray later
that same turn to finish off the weakened defenders.
*I know, only tangentially related, but I wanted to brag.