def reducer(self, key, list_of_v): t = 0 for v in list_of_v: t += v MapReduce.emit(self, (key, t))
def reducer(self,key,list_of_v): t=0 for v in list_of_v: t+=v MapReduce.emit(self,(key,t))
def mapper(self, record): for w in record[1].split(): MapReduce.emit_intermediate(self, w, 1)
def mapper(self,record): for w in record[1].split(): MapReduce.emit_intermediate(self,w,1)