parameters: (acc, new)
return_statement: return ret
docstring: accumulate by the same key in a list of dicts
  
      Args:
          acc(dict): the dict to accumulate to
          new(dict): new dict entry
  
      Returns:
          A new dict containing the accumulated sums of each key.
docstring_summary: accumulate by the same key in a list of dicts
docstring_tokens: accumulate by the same key in a list of dicts
function: def accumulate(acc, new):
      ''' accumulate by the same key in a list of dicts
  
      Args:
          acc(dict): the dict to accumulate to
          new(dict): new dict entry
  
      Returns:
          A new dict containing the accumulated sums of each key.
      '''
      ret = {k: new[k] if a is None else a + new[k]
             for k, a in acc.items() if k in new}
      ret.update({k: v for k, v in new.items() if not (k in acc)})
      return ret
function_tokens: def accumulate ( acc , new ) : ret = { k : new [ k ] if a is None else a + new [ k ] for k , a in acc . items ( ) if k in new } ret . update ( { k : v for k , v in new . items ( ) if not ( k in acc ) } ) return ret