正解得45分的注意了!

P5596 【XR-4】题

啊。。。 ``` typedef long long int_t; for(int_t i=1;i<=n;i++){ //do something } ``` 另外只是longlong没开够爆精度了就没必要发讨论了啊。。
by Rainy_chen @ 2019-10-22 09:21:21


$ 1ll\times i\times i $就可以了
by zzy2333 @ 2019-10-22 09:25:17


我暴力也是45分awa ``` var x,a,b,s,t:int64; begin readln(a,b); x:=-1; while x<50000000 do begin x:=x+1; t:=trunc(sqrt(abs(x*x+a*x+b))); if t*t=x*x+a*x+b then inc(s); end; if s>10000 then writeln('inf') else writeln(s); end. ```
by impuk @ 2019-12-29 12:50:42


|