Point in polygon
The classic geometry test for whether a given point lies inside or outside a polygon.
The usual solution is ray casting: shoot a ray from the point in any direction and count how many polygon edges it crosses — an odd count means inside, an even count outside. The alternative is the winding number, which sums how many times the polygon wraps around the point and handles self-intersecting shapes too. Both run in linear time in the number of edges.
The test underlies hit detection in 2D games, mouse clicks on irregular buttons, geofencing and GIS. For convex polygons a simpler sign test against each edge suffices; for heavy cases the polygon is preprocessed or indexed spatially.