+1 vote
in Data Structures & Algorithms I by (110k points)
What will be the resulting array after reversing arr[]={3,5,4,2}?

(a) 2,3,5,4

(b) 4,2,3,5

(c) 5,4,2,3

(d) 2,4,5,3

Question is from Arrays Types topic in portion Arrays Types of Data Structures & Algorithms I

This question was posed to me in my homework.

1 Answer

+1 vote
by (408k points)
selected by
 
Best answer
The correct answer is (d) 2,4,5,3

Easy explanation - The resulting array upon reversing after reversal is arr[]={2,4,5,3}. We can implement an algorithm for this purpose in various possible ways.

Related questions

Welcome to TalkJarvis QnA, a question-answer community website for the people by the people. On TalkJarvis QnA you can ask your doubts, curiosity, questions and whatever going in your mind either related to studies or others. Experts and people from different fields will answer.

Categories

...