The "adjacent number on the row below" does not contain the "left one"


  • 0
    N

    I got stuck in the definition of the "adjacent numbers on the row below".

    In this problem, the "adjacent number on the row below" does not contain the "left one".

    For instance, the adjacent number of "3" on the row below is {5, 6}, rather than {4, 5, 6}.

    [1],
    [2, 3],
    [4 ,5, 6]

  • -1
    C

    "3"'s adjacent numbers are {4,5,6}. i.e. t[i][j] adjacent numbers are t[i+1][j-1], t[i+1][j], t[i+1][j+1].
    E.g. the min sum is still 7. "2" is followed by "4" (left adjacent num).

    [1],
    [3, 2],
    [4, 5, 6]

  • 0
    F

    Sir, can I ask you one question? if the input is [[-1],[2,3],[1,-1,-3]], then what is expected output?? i thought is -2 where -1+2+-3 but the leetcode answer is -1. I don't get it. We should find the minimum number in each layer right? So for [2,3], the minimum should be 2 not 3. Then it cannot be -1+3+-3 = -1. Am i wrong???


Log in to reply
 

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