Examples
Input: (10, 3, 1, -1, 1, [-1])
Expected Output: True
Explanation: Without jumping, the character moves to position 0 and loses immediately. With a jump, it spends 1 coin, moves safely upward, and survives the only tick.
Input: (8, 4, 5, 0, 2, [-1, -1])
Expected Output: False
Explanation: Jumping now makes the character move to position 9, which is above the top boundary height = 8. Not jumping survives both ticks.
Input: (10, 3, 2, 0, 1, [5, -1, -1, -1])
Expected Output: True
Explanation: Jumping now reaches height 5 on the first tick, collects the coin, and still survives all 4 ticks. Not jumping can also survive all 4 ticks, but ends with fewer coins, so jumping is optimal.
Input: (10, 3, 5, 0, 2, [])
Expected Output: False
Explanation: There are no future ticks to optimize. Both actions are equivalent, so the strategy should avoid an unnecessary jump.
Input: (7, 3, 1, -1, 0, [3])
Expected Output: False
Explanation: The character has no coins, so a jump request has no effect. Both jump and no-jump lead to immediate loss, so return False on the tie.
Input: (9, 2, 3, 1, 1, [4, 4, -1])
Expected Output: False
Explanation: Not jumping collects the coin at height 4 on the first two ticks and survives all 3 ticks. Jumping now rises too high and cannot survive as long.