Source: wikibot/erdos-szekeres-theorem

= Erdős–Szekeres theorem
{wiki=Erdős–Szekeres_theorem}

The Erdős–Szekeres theorem is a significant result in combinatorial geometry and discrete mathematics. It addresses the problem of monotone subsequences in sequences of points in the plane. The theorem states that for any integer \\( n \\), any sequence of \\( n^2 \\) distinct points in the plane, no three of which are collinear, contains either: 1. An increasing subsequence of length \\( n \\), or 2. A decreasing subsequence of length \\( n \\).