Score Maximiser
CodeChefOpen on judge ↗
You are given a non-empty, zero-indexed array A of n (1 <= n <= 100000) integers a0, a1, . . . , an−1 (0 <= ai <= 1000). This array represents the score of tiles on the consecutive spots along a long road of tiles. You are also given integers k and m (0 <= k, m < n). A person is at tile number k on the road and should perform m moves. In one move she moves to an adjacent spot. When she visits a t
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