Блог пользователя bukunu

Автор bukunu, история, 6 лет назад, По-английски

Asked in a Finance Company Interview :

Given three unsorted arrays A,B and C, the task is to find three elements a,b,c from the three arrays such that a+b=c.

Can it be done in O(nlogn)?

Suppose the arrays are given as sorted, then can it be done in linear time?

Полный текст и комментарии »

  • Проголосовать: нравится
  • +11
  • Проголосовать: не нравится