Pikachu and Stones
CodeChefOpen on judge ↗
Charizard and Dragonite have a Pokemon tournament scheduled today. In order to keep Pikachu busy they gave him a task. He is given $N$ piles of stones with where $i^{th}$ pile has $A_i$ stones, and his task is to make a peak from the piles of stones without moving stones from one pile to another. Collection of piles make a peak if the no of stones in the pile is strictly increasing from inde
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