How does my digital watch keypad work?
It's probably an array of buttons, but with a confusing looking layout. Where the MCU will compare which row and column is live. Here is a button array available from eBay for an Arduino.



You can see that there isn't a pin for every button, only for every row and column.