parameters: (self, nums, k)
return_statement: return result
docstring: :type nums: List[int]
          :type k: int
          :rtype: List[int]
docstring_summary: :type nums: List[int]
          :type k: int
          :rtype: List[int]
docstring_tokens: : type nums : List [ int ] : type k : int : rtype : List [ int ]
function: def getAverages(self, nums, k):
          """
          :type nums: List[int]
          :type k: int
          :rtype: List[int]
          """
          total, l = 0, 2*k+1
          result = [-1]*len(nums)
          for i in xrange(len(nums)):
              total += nums[i]
              if i-l >= 0:
                  total -= nums[i-l]
              if i >= l-1:
                  result[i-k] = total//l
          return result
function_tokens: def getAverages ( self , nums , k ) : total , l = 0 , 2 * k + 1 result = [ - 1 ] * len ( nums ) for i in xrange ( len ( nums ) ) : total += nums [ i ] if i - l >= 0 : total -= nums [ i - l ] if i >= l - 1 : result [ i - k ] = total // l return result