Latest Technical code puzzle logical quantitati Aptitude Question SOLUTION: Boxes are arranged 1 beside the other.
Each box is numbered with a number which represents the number of boxes it may jump(skip).
Find the minimum number of jumps required to reach
Boxes are arranged 1 beside the other.
Each box is numbered with a number which represents the number of boxes it may jump(skip).
Find the minimum number of jumps required to reach last box.
Ex: Boxes are numbered as follows :
Index 1 2 3 4 5 6 7 8 9
Number 2 3 1 2 1 1 4 2 1
Solution : Min. no. of jumps = 5
Starting from 1st box which is labelled 2, we can jump to 2 boxes or 1 box.
i.e. to Box numbered 3 or 1
From that 3 or 1 we can continue.
Here we have following solutions pairs index numbered from 1 to 9: