re: Daily Coding Puzzles - Nov 4th - Nov 9th VIEW POST

TOP OF THREAD FULL DISCUSSION
re: Tuesday Product of Array Items (7 KYU): Calculate the product of all elements in an array. CodeWars
 

Python!

def product(numbers):
    if not numbers: return None
    running_product = 1
    for number in numbers:
        running_product *= number
    return running_product
 
def product (numbers):
  return reduce(lambda total, number: total * number, numbers)
code of conduct - report abuse