If spears are often described as better than swords both in a duel and battle why were they used so often?
sources: https://m.youtube.com/watch?v=afqhBODc_8U [video] https://m.youtube.com/watch?v=d86sT3cF1Eo [video]
The short answer is that
you can wear a sword at your side, while working, indoors, etc., and
spearmen and archers like to have swords as sidearms.
A spear being "better" is conditional, not absolute. So it's useful to carry a versatile sidearm.
For more, see my past answer in https://www.reddit.com/r/AskHistorians/comments/ae3b17/if_spears_were_generally_better_than_swords_why/