update
This commit is contained in:
parent
4220c362fa
commit
489dd58f85
@ -88,7 +88,7 @@ static void init(){
|
|||||||
c[i][j] = (c[i-1][j-1] + c[i-1][j])%k;
|
c[i][j] = (c[i-1][j-1] + c[i-1][j])%k;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
for(ull i = 2;i<max_n-1;i++){ //t被修改
|
for(ull i = 2;i<max_n;i++){ //注意这里越界了,这是个bug示例
|
||||||
for(ull j{1};j<=i;j++){
|
for(ull j{1};j<=i;j++){
|
||||||
prefix[i][j] = prefix[i-1][j]+prefix[i][j-1]-prefix[i-1][j-1] + (c[i][j]==0?1:0);
|
prefix[i][j] = prefix[i-1][j]+prefix[i][j-1]-prefix[i-1][j-1] + (c[i][j]==0?1:0);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user