Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
Golden Pyramid solution in Uncategorized category for Golden Pyramid by capback250
# migrated from python 2.7
def count_gold(pyramid):
tr = [list(x) for x in pyramid]
for i in range(len(tr)-2, -1, -1):
print(i)
for j in range(i + 1):
tr[i][j] += max(tr[i + 1][j], tr[i + 1][j + 1])
return tr[0][0]
Oct. 28, 2015