从下到上每层计算通项公式 top(m,n)=max(top(m+1,n),top(m+1,n+1)+tree[m][n],最底层时top(m,n)=tree[m][n],最好用一位数组存储中间结果,
点赞 评论

相关推荐

牛客网
牛客网在线编程
牛客网题解
牛客企业服务