CONSTRUCT BINARY TREE FROM STRING | LEETCODE 536 | PYTHON STACK SOLUTION

Поделиться
HTML-код
  • Опубликовано: 7 фев 2025
  • НаукаНаука

Комментарии • 5

  • @Ermorder1
    @Ermorder1 6 месяцев назад

    Interesting problem, thank you for your video. There can be another follow up like put open and close brackets "()" to input to show None for the left node.

  • @vivek.tiwary
    @vivek.tiwary 5 месяцев назад

    What about the inner loop, it can go for n elements of the string ?

  • @TheSmashten
    @TheSmashten 3 месяца назад

    Brilliant

  • @translatingIdeasIntoCoding
    @translatingIdeasIntoCoding 4 месяца назад

    why don't you just track the level? Increment level on "(", decrement level on ")", add number to result on numbers regarding to the level.

  • @clatttheman3550
    @clatttheman3550 6 месяцев назад

    discord invite is invalid