Fix #2: Make sure 0-weight cards are never selected
This commit is contained in:
parent
a73b0c48a6
commit
cd9b330a1f
|
@ -39,7 +39,7 @@ void query(int *res, int v, int l, int r, int n) {
|
|||
return;
|
||||
}
|
||||
int m = l + r >> 1;
|
||||
if (seg[n << 1] >= v) {
|
||||
if (seg[n << 1] > v) {
|
||||
query(res, v, l, m, n << 1);
|
||||
}
|
||||
else {
|
||||
|
|
Loading…
Reference in New Issue