1) It is not clear how to decide this 'i' from your solution and why
ignore first logN persons. Can you tell me where exactly in CLR is this
problem discussed?
2) O(n^2) is trivial and is brute force. From what I heard, O(n) soln
exists.
3) No O(n log n) is too expensive. O(n) is possible. Can DP help here?
I don't know the solutions to any of these so let me know your
thoughts.

Reply via email to