Re: [algogeeks] Minimum number of jumps to reach end

2012-01-25 Thread shady
http://www.geeksforgeeks.org/archives/13209 On Thu, Jan 26, 2012 at 10:33 AM, Sanjay Rajpal wrote: > Given an array of integers where each element represents the max number of > steps that can be made forward from that element. Write a function to > return the minimum number of jumps to reach the

[algogeeks] Minimum number of jumps to reach end

2012-01-25 Thread Sanjay Rajpal
Given an array of integers where each element represents the max number of steps that can be made forward from that element. Write a function to return the minimum number of jumps to reach the end of the array (starting from the first element). If an element is 0, then cannot move through that elem