Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
Minimal, simple solution. solution in Clear category for Golden Pyramid by dunpealer
def count_gold(pyramid):
best = list(pyramid[-1])
for row in reversed(pyramid[:-1]):
for c, n in enumerate(row):
best[c] = n + max(best[c], best[c+1])
return best[0]
Sept. 6, 2015