• + 0 comments

    Actually there's an O(n log n) solution - calculating in O(n/x) for each "x" mentioned in editorial :)