1.

In how many different ways we can reach the end of the array arr[]={1,3,5,8,9}?(a) 1(b) 2(c) 3(d) 4Asked question is from Number of Jumps to Reach End-array Operation topic in portion Arrays Types of Data Structures & Algorithms IThe question was asked in homework.

Answer»

The CORRECT answer is (d) 4

The best I can explain: There are 4 possible ways in which we can REACH the END of the array. The possible paths are – 1->3->5->8->9, 1->3->5->9, 1->3->8->9, 1->3->9.



Discussion

No Comment Found

Related InterviewSolutions