 If we allow randomization to be used together with the floor function, the problem can be solved in time.The closest pair of points can be computed in O("n"2) time by performing a brute-force search.To do that, one could compute the distances between all the pairs of points, then pick the pair with the smallest distance, as illustrated below.