re: Daily Challenge #110 - Love VS. Friendship VIEW POST

FULL DISCUSSION
 

My solution to the challenge using map and reduce in Python. If anyone has any suggestions on how to improve it, I would love to hear! :)

from functools import reduce 
def wordsToMarks(word):
    print(reduce((lambda x,y: x+y), map((lambda x: ord(x) - 96), list(word))))
code of conduct - report abuse