grandyang / leetcode

Provide all my solutions and explanations in Chinese for all the Leetcode coding problems.
6.14k stars 736 forks source link

i have a question in the Answer ? #2008

Open blantt opened 3 years ago

blantt commented 3 years ago

excuse me, i think.. if try a array= [2,4,9] ,the k=2 this answer=3 but if (9-2) - (4+2) =1 the 1 why not the best smaill ??

thks!