nums[i] is the maximum jump length from position i. Starting at index 0, implement in O(n):
can_reach_end(nums): whether the last index is reachablemin_jumps(nums): the minimum number of jumps to reach the last index, or -1 if impossible. Think of it as BFS where each "level" is the range of indices reachable with a given number of jumps.