inf居然0x7f7f7f7f都不够,要赋值为9000000000000000000!

P1314 [NOIP2011 提高组] 聪明的质监员

暮光闪闪 @ 2019-07-29 15:14:13

这道题要用long long。而且const long long inf居然0x7f7f7f7f都不够,要赋值为9000000000000000000!

这个鬼东西坑了我好久!改了一上午,这太毒瘤了吧!


by yuio @ 2019-07-29 15:16:44

0x7f还在int范围里。。不够很正常吧


by WYXkk @ 2019-07-29 15:18:24

@晨晖烁烁 Are you kidding?0x7f7f7f7f=2139062143,远远小于9000000000000000000.


by fzfnf @ 2019-07-29 15:19:02

@晨晖烁烁

为毛不用std::numeric_limits


by 暮光闪闪 @ 2019-07-29 15:21:27

是我太


by Lice @ 2019-07-29 15:26:53

LONG_LONG_MAX


by Hemingway @ 2019-07-29 15:27:39

0x7fffffffffffffffll


by first_fan @ 2019-07-29 15:40:34

为什么不1e15或是1e18呢?

你要是乐意,开高精存inf也成


by GoldenFishX @ 2020-01-20 16:08:20

@Wallace

LLONG_MAX


by 徐崇瑜 @ 2022-01-06 21:21:34

为何不用 9.2e18


|