|
|
вернуться в форумI use double hash but still tle. and i do not know how to use fread, fwrite in online judge,please help my algo should be n*50*order of hash probably large input is causing problem i can use fread and fwrite but don't know how to do it in online judge submission. please provide me with some code segment that utilize fread and fwrite. better be some eg problem as 1000. a+b problem thanks in advance. Re: I use double hash but still tle. and i do not know how to use fread, fwrite in online judge,please help So did i. did you find some methods to solve it? please help me.thx a lot. Re: I use double hash but still tle. and i do not know how to use fread, fwrite in online judge,please help yes. my hash was correct. but i used long long for calculation. i replaced with int except for one case and got ac. anyway my mod value for double hash was 499979. hash using just those 3 integers in 2e8 radix system and avoid long long as much as possible. good luck. anyway i still want to know the fread, fwrite magic. as so many problems i got ac in 0.015 sec but best timing was 0.001 sec. if u know, please help. Edited by author 29.03.2011 22:28 |
|
|