Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
Second solution in Clear category for Golden Pyramid by yukirin
def count_gold(pyramid):
result = [list(steps) for steps in pyramid]
for i in range(len(result[1:])):
for j in range(len(result[i + 1])):
result[i + 1][j] += max(result[i][max(j - 1, 0)], result[i][min(j, i)])
return max(result[-1])
April 14, 2015