Thanks. My mistake



所有跟贴·加跟贴·新语丝科技论坛

送交者: Duke 于 2005-2-11, 19:32:37:

回答: casting is all right for me 由 enable 于 2005-2-11, 19:03:31:

This is what I did:

double d = 0.5;

int i = (int) 0.5 / d;

Casting there was not effective. But this works:

int i = (int) (0.5 / d);

Thanks again.






所有跟贴:


加跟贴

笔名: 密码(可选项): 注册笔名请按这里

标题:

内容(可选项):

URL(可选项):
URL标题(可选项):
图像(可选项):


所有跟贴·加跟贴·新语丝科技论坛