https://www.hackerrank.com/challenges/angry-children/problem?isFullScreen=true
코드(성공)
def maxMin(k, arr):
# Write your code here
arr.sort()
mn = arr[-1] - arr[0]
for i in range(k-1, len(arr)):
cur = arr[i] - arr[i-(k-1)]
if cur < mn:
mn = cur
return mn