Oxidation numbers of phosphorus pentachloride I read detailed explanations of what oxidation numbers/ states represent and it boils down simply to this: If it's positive, it shows how many electrons the element lost, and in the case of a negative oxidation number, it shows how many electrons the element gained. That I understand.

What I don't get is, in Phosphorus pentachloride $\ce{PCl5}$, phosphorus forms 5 single bonds with chlorine atoms and 'gains' $5$ more electrons to accommodate a total of $10$ electrons. Shouldn't its oxidation number be $-5$ instead of $+5$?
When considering the oxidation state of covalent compounds, we need to pretend they are ionic. When we do so, we assign all of the electrons to the more electronegative element. The electronegativity of phosphorous using the Pauling Scale is 2.19 and the electronegativity of chlorine is 3.16. Since chlorine is the more electronegative element, we assign all electrons in the bonds to the chlorine atoms. Thus $\ce{PCl5}$ is treated as the fictitious ionic compound comprised of $\ce{P^{5+}}$ ions and $\ce{Cl-}$ ions.