Question from a Sprinklr interview

Правка en1, от guptaji30, 2022-01-20 07:32:10

Given an array, arr[] of integers. The task is to sort the elements of the given array in the increasing order of their modulo with 3 maintaining the order of their appearance.

Expect time complexity O(N) and the interviewer said that it can be done in only one traversal.

Expected space complexity O(1).

Теги array, sorting, interview

История

 
 
 
 
Правки
 
 
  Rev. Язык Кто Когда Δ Комментарий
en2 Английский guptaji30 2022-01-20 10:56:56 70
en1 Английский guptaji30 2022-01-20 07:32:10 348 Initial revision (published)