Search⌘ K
AI Features

Erect the Fence

Erect the Fence gives you unique tree locations as two-dimensional points. Return every tree on the perimeter of the shortest fence enclosing all the trees, in any order.

Statement

You are given an array of points, trees, where trees[i] = [xᵢ, yᵢ] represents the location of a tree ...