Instead of using bottom-up method, is there a top-down method?


  • 0
    A

    I was thinking whether this problem can be solved by top-down method? I know it may be not as efficient as the bottom-up ones, but I am thinking whether it can be solved this way.

    Many thanks for your help!


  • 0
    Y

    What do you mean by "top-down"?

    I think ,we agree that in the actual computing process, the bottom height is determined first and then the top height is in turn determined. But using recursion the coding can be in a top-down fashion.


Log in to reply
 

Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.