Online Judge | Problem Set | Authors | Online Contests | User | ||||||
---|---|---|---|---|---|---|---|---|---|---|
Web Board Home Page F.A.Qs Statistical Charts | Current Contest Past Contests Scheduled Contests Award Contest |
请问这两段代码有何区别?(注释的和未注释的,一份ac,一份wa)void modify(int x,int y,int delta){//这两段程序有区别?,为这个我错了2个小时!!!求教,这二者的区别!!! int i,j,k; /* for (;x<=n;x+=lowbit(x)) for (;y<=n;y+=lowbit(y)) tree[x][y]+=delta; */ for (i=x;i<=n;i+=lowbit(i)) for (j=y;j<=n;j+=lowbit(j)) tree[i][j]+=delta; } Followed by:
Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator