You may use a map first to store num->frequency and then a multimap to ... int c[n]; // vector which stores the frequency of each element for(int i=0; i<n; ...
確定! 回上一頁