1.

Reversal algorithm and juggling algorithm for array rotation have the same time complexity.(a) True(b) FalseI would like to ask this question from Arrays Types in section Arrays Types of Data Structures & Algorithms IThis question was posed to me in semester exam.

Answer»

The correct choice is (a) True

The best explanation: Time complexity of JUGGLING algorithm is O(n) which LIKE that of reversal algorithm. They ALSO have the same SPACE complexity.



Discussion

No Comment Found

Related InterviewSolutions