Google | Phone Screen
Anonymous User
548

1)Given a unsorted array .Find the index of the given element in the array if it was sorted.
eg. a=[11,33,22,33]
Given element=22
The output should be 1.

2)Follow up question
Given a unsorted array.Find the indices of the mode element if the array was sorted.
eg. a=[11,33,22,33]
the output should be {2,3}

Comments (4)