Algorithm probably has to be O(n^2). Look into optimizations.
Algorithm probably has to be O(n^2). Look into optimizations.