You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
要判断list的容量与k-topk.size()的大小。不然下标会越界。
int size=k-topk.size()>buckets[i].size()?buckets[i].size():k-topk.size();
topk.addAll(buckets[i].subList(0,size));