Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
First solution in Clear category for Golden Pyramid by StanislauL
def count_gold(pyramid):
down = list(pyramid[-1])
for line in pyramid[-2::-1]:
tmp = []
for x in range(len(line)):
tmp.append(line[x] + max([down[x], down[x+1]]))
down = tmp
return down[0]
Aug. 15, 2017