DP on Treestreeoptimization
Max Height of Tree when any Node can be Root
Given an undirected tree, for every possible choice of root node, find the height of the tree, the number of edges on its longest downward path to a leaf, when rooted at that node.
Do this lesson first: house robberThe full breakdown and animated table for this problem are still being written. In the meantime, run the four questions on it yourself — that is the whole exercise.