I have just submitted to this problem: Problem D but my O(N*In N*log2(1e9)) solution didn't pass test 6. submission Is it because I am using long longs and thus allocating memory too carelessly, or is it just because I am spamming modulo operations while calculating the solution? Any help will be much appreciated







