HELP NARUTO
CodeChefOpen on judge ↗
Kakashi is conducting a training game for Naruto. There is a path which Naruto has to follow. This path contains $N$ no of chakras. Each chakra has a value $Ai$ which can be both positive of negative. Naruto has a choice to absorb or ignore the chakras. A positive chakra can increase his power whereas a negative chakra can decrease his power. Initially Naruto has 0 power. Now if at any point h
HINT LADDERno hints yet
L1 Observation
L2 Technique
L3 Approach
L4 Pseudo-code
🔒
L5 Full solution
L5 unlocks only if you insist twice
solution.cppC++17
CodeSearch Tutor
Hints, not spoilers — it won’t hand over the full solution unless you insist.
Sign in to chat with the tutor and save your progress.
Sign in to start