code: def sum(self, projection=None):
          
          if projection:
              return sum(self.map(projection))
          else:
              return sum(self)
docs: Takes sum of elements in sequence.
  
          >>> seq([1, 2, 3, 4]).sum()
          10
  
          >>> seq([(1, 2), (1, 3), (1, 4)]).sum(lambda x: x[0])
          3
  
          :param projection: function to project on the sequence before taking the sum
          :return: sum of elements in sequence