Difficulty Level: MEDIUM
Problem Statement:
Given an array arr[] where each element represents the max number of steps that can be made forward from that index. The task is to find the minimum number of jumps to reach the end of the array starting from index 0. If the end isn’t reachable, return -1.
Input:
arr[] = {1, 3, 5, 8, 9, 2, 6, 7, 6, 8, 9}
Output:
Minimum number of jumps to reach end is 3