The Spanish words 'año' ('year') and 'España' ('Spain') contain the letter ñ, which is called eñe.
It comes from a double nn. One of the n's was abbreviated as a squiggle on top of the other: ñ.
For instance, 'año' comes from Latin 'annum' with nn.
However, 'puño', 'España' and 'viña' come from 'pūgnum', 'Hispāniam' and 'vīneam', which didn't have nn.
My graphic explains how they got their ñ:


feld
in reply to John-Mark Gurney • • •