Available question text
Given a multiset of 2n numbers that are exactly the values arr[i]-k and arr[i]+k for some unknown positive k, recover arr by finding a positive k such that the numbers can be paired into n couples with difference 2k and taking each arr[i] as the midpoint of its pair — typically done by sorting and greedy multiset/counter pairing using candidate differences from the smallest element.
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 2122. Recover the Original Array
Interview date not specified · 0 source reports
Source snapshot: Nov 12, 2026
View source