Article View: comp.std.c
Article #4596Re: int's and zero
From: rex
Date: Tue, 09 Jan 1996 18:09
Date: Tue, 09 Jan 1996 18:09
21 lines
1454 bytes
1454 bytes
> eivind@odin.funcom.com (Eivind Eklund) writes:
> Are zero in an integer required to be represented by binary zeros?
There was considerable debate about whether or not integers could be stored
as BCD, Grey code, or some such, but in the end, we decided that they had to
be stored as binary numbers. And, of course, 2's comp, 1's comp, and signed
magnitude all use all-bits-zero for zero. The only thing that could cause a
problem is for machines/compilers with signed zeros; I think that negative
zero might have some other bit pattern.
Rex
----------------------------------------------------------------------------
+1 703 860-0091 | Rex Jaeschke | C and C++ Seminars
FAX +1 703 860-3008 | 2051 Swans Neck Way | and Consulting
rex@aussie.com | Reston, Virginia 22091, USA |
----------------------------------------------------------------------------
Chair of X3J11 (ANSI C) and participant in SC22/WG14 (ISO C). Columnist for
NT Developer, VC++ Professional, and Enterprise NT.
----------------------------------------------------------------------------
Technical Details
Message-ID:
<4cub1a$jbl@alterdial.UU.NET>Path:
arc1-ca.pugleaf.net!alterdial.uu.net!not-for-mailReferences:
<4cth4e$4q@odin.funcom.no>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!alterdial.uu.net!not-for-mail From: rex@aussie.com Newsgroups: comp.std.c Subject: Re: int's and zero Date: 9 Jan 1996 18:09:46 GMT Message-ID: <4cub1a$jbl@alterdial.UU.NET> References: <4cth4e$4q@odin.funcom.no> NNTP-Posting-Host: pool041.max1.ffx1.va.dynip.alter.net X-Newsreader: SPRY News 3.03 (SPRY, Inc.)