How does a touchscreen know exactly where you tapped?
Most modern touchscreens use capacitive technology. Your finger conducts electricity, and the screen has a grid of transparent electrodes running horizontally and vertically across it. When you touch the surface, your finger disturbs the electrical field at that specific intersection point, causing a measurable change in capacitance. The controller chip reads signals from all the electrodes simultaneously and calculates the precise x and y coordinates by identifying which row and column show the strongest disruption.
Older resistive screens worked differently, using two flexible conductive layers that physically pressed together when tapped, completing a circuit at that location. Capacitive screens are more accurate and support multi-touch because they can detect multiple simultaneous disturbances across the entire grid at once.