Coming soon - Get a detailed view of why an account is flagged as spam!
view details

This post has been de-listed

It is no longer included in search results and normal feeds (front page, hot posts, subreddit posts, etc). It remains visible only via the author's post history.

12
Maximum Path of Number Triangle
Post Body

I’ve been looking into number triangles and noticed there are several algorithms that can be used to work out the maximum sum path of the triangle using dynamic programming.

One such article:https://www.geeksforgeeks.org/maximum-path-sum-triangle/amp/

All the algorithms seem to print out only the final sum. I’m curious if there is a way to keep track of the addends that make up that final sum? I tried coding something up out of curiosity but found that when I tried to keep track of the used addends, the time complexity became horrendous (something like 2n)

Author
Account Strength
50%
Account Age
2 years
Verified Email
Yes
Verified Flair
No
Total Karma
109
Link Karma
52
Comment Karma
32
Profile updated: 5 days ago
Posts updated: 1 year ago

Subreddit

Post Details

We try to extract some basic information from the post title. This is not always successful or accurate, please use your best judgement and compare these values to the post title and body for confirmation.
Posted
2 years ago