Available question text
Given apples at each integer point (i, j) equal to |i|+|j|, find the smallest axis-aligned square centered at the origin whose contained lattice points sum to at least neededApples; this reduces to deriving a closed-form formula for the total apples inside a square of half-side k and binary-searching the minimal k (perimeter = 8·k) under large (≤1e15) inputs.
Related questions
Continue with questions that share topics or the same question type.
Sources · 1 reference
These records explain where the question appears. A company tag or candidate report does not guarantee a future interview question.
Hello Interview · 1 record
No company association
Leetcode 1954. Minimum Garden Perimeter to Collect Enough Apples
Reported date not specified · 0 source reports
Source snapshot: Nov 12, 2026
View source