about | help | code help+videos | done | prefs |
beaverPond Benny Beaver Benny the Beaver is building a new pond. He wants a pond with the maximum volume of water. He will need to build two dams. During rainy seasons the water will top over the dams and fill the pond with water. In dry seasons both dams will maintain the water level in the pond. Benny has access to different points on a creek with nearby groves of lumbers of different height, but the trees in each grove limits the height of the dams at the different locations. Given an array where the beaverPond([2, 7, 2]) → 4 beaverPond([2, 7, 2, 7]) → 14 beaverPond([1, 8, 6, 2, 5, 4, 8, 3]) → 40 ...Save, Compile, Run (ctrl-enter) |
Progress graphs:
Your progress graph for this problem
Random user progress graph for this problem
Random Epic Progress Graph
Difficulty: 200 Post-solution available
Copyright Nick Parlante 2017 - privacy