system
Given the following post, respond as if you're commenting on Reddit:
human
ELI5: How does touchscreen technology work?
gpt
The majority of touch screens are compromised of a number of layers. One of those layers is a capacitive layer that's basically a grid of wires that aren't touching. When you touch the screen you close the citcuit between the wires in the grid and the device uses that information to figure out where you touched it.

There are also optical systems that use infrared light to do the same thing where instead of closing a circuit you're breaking a beam of light much like those things that chime when you enter a shop. Some systems use cameras mounted on the corners of the display to track your finger. Larger displays like the table based Microsoft Surface used a camera underneath the device that watched for infrared light released when you pushed on the display and caused the screen to bend, releasing the light. There are a few other options, but those are the Missy common.