Path: utzoo!attcan!uunet!ncrlnk!ncr-sd!hp-sdd!hplabs!ucbvax!HUB.UCSB.EDU!bfox%eagle From: bfox%eagle@HUB.UCSB.EDU (Brian Fox) Newsgroups: comp.sys.apple Subject: Long and short integers Message-ID: <8811221659.AA15060@hub.ucsb.edu> Date: 22 Nov 88 16:59:03 GMT References: <8811220359.aa03637@SMOKE.BRL.MIL> Sender: daemon@ucbvax.BERKELEY.EDU Reply-To: bfox%cornu@hub.ucsb.edu Organization: The Internet Lines: 40 Posted-Date: Tue, 22 Nov 88 02:55:53 CST Date: Tue, 22 Nov 88 02:55:53 CST From: Brian Glaeske In reply to the question about how the computer stores numbers. Most, I dare say ALL computers use what is called Most Significant Bit, and Least Significant Bit. These are the biggest and the smallest part of the the number respectfully. The MSB is store in the highest memory location, because it is bigger. And the LSB is stored in the lowest memory location, because of course it it smaller. I hope this answers the senders question. Hah! That's pretty funny. Even though I suspect you are joking, some people may believe you, and so I feel compelled to explain MSB and LSB. The MSB is the Most Significant because it is has the most significance in determing the value of the number. In the decimal system the most significant digits are always on the left; put another way, the digits closer to the left represent higher magnitudes than the digits closer to the right. In the number 235, the `2' is the most significant digit, and the `5' is the least significant. When a computer CPU (brain) is manufactured, the designer makes a decision as to which `end' of a byte is going to contain the MSB. This decision is practically arbitrary. It is usually based on a combination of hardware design and compatibilty with other existing hardware. In the Apple, the MSB is the leftmost bit in the byte. If you need several bytes worth of bits to represent a large number, then the byte at the lowest memory address contains the MSB (and in fact, is known as the Most Significant Byte). Brian Fox PS: If this isn't clear, learn how to count in binary on your fingers, and then do it in a mirror.