def factors(numer):
return set(reduce(list.__add__, ([i, numer//i] for i in range(1, int(numer**0.5) + 1) if numer % i == 0)))
I'm trying to find the different sets of factors for the value "numer" but it gives me an error saying:
NameError: name 'reduce' is not defined
What could I replace reduce with to make my code work?