Function to find all possible paths to reach end of array requiring minimum number of steps
public static void possiblePath ( int [ ] arr , int [ ] dp ) { Queue queue = new Queue ( ) ; queue . Enqueue ( new Pair ( 0 , "0" , dp [ 0 ] ) ) ; while ( queue . Count > 0 ) { Pair tmp = ( Pair ) queue . Dequeue ( ) ; if ( tmp . jmps == 0 ) { Console . WriteLine ( tmp . psf ) ; continue ; } for ( int step = 1 ; step <= arr [ tmp . idx ] ; step ++ ) { if ( tmp . idx + step < arr . Length && tmp . jmps - 1 == dp [ tmp . idx + step ] ) {