__Tanzeel__'s blog

By __Tanzeel__, history, 2 years ago, In English

Yesterday there was a online test of some website (GeeksforGeeks) where I encountered the below problem, I was not successful in getting AC for the problem because of TLE issue, it will be very helpful if someone can share the approach or give hints to solve the problem ,below I am attaching the problem statement. My time complexity of the solution was O(N.x) where 'x' is the frequency of maximum element of the given array.    Any help will be appreciated.

Full text and comments »

  • Vote: I like it
  • -2
  • Vote: I do not like it