Company: StoneX_22july
Difficulty: medium
Prime Jumps Problem Description Consider a board game with these rules: A token begins on Cell 0 carrying a running total of 0. The board has n cells, numbered 0 through n-1. Every cell holds an assigned number, and cell 0's number is always 0. On each turn, the token may either: Advance exactly one cell, or Advance p cells, where p is a prime number whose last digit is 3 (for instance 3 or 13). The token can never move past the last cell. Whenever the token lands on a cell, that cell's number is added to the running total. Play ends once the token lands on the final cell, n-1. Work out the highest running total achievable. Examples Example 1: Input: cell = [0, -10, -20, -30, 60] Output: 40 Explanation: This board has n = 5 cells, numbered 0 through 4. From cell 0, the token is able to reach cells 1 and 3 directly. Advancing one cell at a time is always available, all the way to cell n-1. 3 qualifies as a prime number ending in the digit 3. There are three ways to reach cell 4: Jump 3