Just learned how to type Spanish accents, ¡ and ¿ on my keyboard if you were wondering, too
On a Mac, press the 'option' button + letter, press the letter again.
example: 'option' button + letter N = ˜
when I press N again, it puts the N under the tilda = ñ
For Mac, use the CTRL button.
I found the instructions here:
https://www.spanishdict.com/guide/how-to-type-spanish-accents-and-letters

