Mode: On-Campus Exam Pattern: 2 Coding + 10 MCQ on AIML OA Date: 2026-10-17
You are given two integer arrays, x and y, of length n, where the i-th point has coordinates (x[i], y[i]).
You are also given an integer k. Find the minimum possible area of an axis-aligned square that strictly encloses at least k points.
A square is axis-aligned if its sides are parallel to the coordinate axes.
A point is strictly enclosed by the square only if it lies strictly inside the square. Points lying on any of its four boundaries are not considered enclosed.
n and k.n space-separated integers representing the x coordinates.n space-separated integers representing the y coordinates.Print the minimum possible area of an axis-aligned square that strictly encloses at least k points.
1 <= k <= n1 <= n <= 10^5