
This might work assuming initially power of bot was 0 and power is not increasing in between transitions except the ones mentioned in question.
From level 0, with i/p as 0 (power) the bot will hit any one amongst 3 obstacles leading to o/p power= -1. [reaches 1st level]
Since bot was not successful, so it has to cross another obstacle in level 2.
Now, while making transitions to 2nd level the bot will cross 2 other obstacles of 1st level, it will gain +2 power, but will also loose -1 on being hit by new obstacle in 2nd level.Total o/p power=-1(from previous level) +2(gain) -1(2nd level obstacle)=0
Finally, while transitioning from second level to last level, it will gain +1 for crossing alternate obstacle of level 2, o/p power=0+1=1