In [8]:
#!/usr/bin/python
import itertools
flatten_iter = itertools.chain.from_iterable

In [9]:
def factors(n):
    return set(flatten_iter((i, n//i) 
        for i in range(1, int(n**0.5)+1) if n % i == 0))

In [6]:
goal = 34000000
i = 1

while not (sum(list(factors(i)))*10) > goal:
    i += 1
print ("house", i)


house 786240

In [ ]:


In [ ]: