由买买提看人间百态

boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
Programming版 - 居然有正负零
相关主题
简单问题的有限差分求题目
what does "a & -2" mean?求题目
[合集] 微软另一道智力题,求救google 真的很强大!?
pyQT的性能求网站建设合作者(二期修正及开发)
这种数值的问题怎么办呢Usage of Grep???help!!!
请教一个算法问题 (转载)how to print 2 exponential digits in windows by using Perl
建议版主删除黑各种语言的帖子How to encode YYYY-MM-DD?
how to get division and reminder in one operation?一道C++面试编程题
相关话题的讨论汇总
话题: complement话题: digit话题: sign话题: first话题: conp
进入Programming版参与讨论
1 (共1页)
x*****u
发帖数: 3419
1
气煞我也。
但不知道怎么用。。?
x*****u
发帖数: 3419
2
ieee 里面定义有正负零。
j***y
发帖数: 2074
3

这只是编码方式用1's complement引起的吧。
2's complement就可以消除这个问题了。

【在 x*****u 的大作中提到】
: ieee 里面定义有正负零。
c*****t
发帖数: 1879
4
Floating point represenation still has the problem of -0.

【在 j***y 的大作中提到】
:
: 这只是编码方式用1's complement引起的吧。
: 2's complement就可以消除这个问题了。

c********g
发帖数: 449
5
-0 = 1.00000
0 = 0.00000
first digit is sign.
it is 2's complement

【在 c*****t 的大作中提到】
: Floating point represenation still has the problem of -0.
a***x
发帖数: 26368
6
2's conp has -0?

【在 c********g 的大作中提到】
: -0 = 1.00000
: 0 = 0.00000
: first digit is sign.
: it is 2's complement

c********g
发帖数: 449
7
-0 = 1.00000
0 = 0.00000
first digit is sign.
it is Signed Magnitude
-0 = 1.11111
0 = 0.00000
first digit is sign.
it is 1's complement
2's complement only has one zero 0.00000.
flip and add 1at last position it is 0.00000 also.
thanks alexx for reminding me

【在 a***x 的大作中提到】
: 2's conp has -0?
1 (共1页)
进入Programming版参与讨论
相关主题
一道C++面试编程题这种数值的问题怎么办呢
Interview question for Quant to share-2, please discuss and help each other请教一个算法问题 (转载)
求教vpa后画图问题建议版主删除黑各种语言的帖子
C++怎么不打印小数结尾的0how to get division and reminder in one operation?
简单问题的有限差分求题目
what does "a & -2" mean?求题目
[合集] 微软另一道智力题,求救google 真的很强大!?
pyQT的性能求网站建设合作者(二期修正及开发)
相关话题的讨论汇总
话题: complement话题: digit话题: sign话题: first话题: conp