IHaveBeenToldWhatToDo's blog

By IHaveBeenToldWhatToDo, history, 7 years ago, In English

I can't find my mistake on this solution for this problem. Problem: http://www.spoj.com/problems/ADATREE/ Solution: https://pastebin.com/QjFae67a

»
7 years ago, # |
  Vote: I like it 0 Vote: I do not like it

Good day to you,

try following input


11 1 23 18 22 6 22 10 20 4 28 9 0 10 10 2

If I'm not mistken, the answer shall be "0", is that true?

Good Luck & Have Nice Day