1. Home
  2. Computing & Technology
  3. C / C++ / C#

Definition of Endian

By , About.com Guide

Definition: This refers to the layout of (usually ) bits in CPUs and affects the layout of multi byte numbers, particularly integers. There are two schemes that really matter- big endian and little endian. PCs for example are little endian (which means little end first). Motorola processors used in Macs (uitil the switch to Intel processors) were big endian.

For example the decimal int 56789652 is 0x03628a94 in hexadecimal. On a big endian PC the 4 bytes in memory at address 0x18000 start with the leftmost hex digit. Each 8 bit memory location holds one hexadecimal number in the range 0x00 to 0xxFF.

Big Endian
18000 18001 18002 18003
0x03 0x62 0x8a 0x94

Little Endian
18000 18001 18002 18003
0x94 0x8a 0x62 0x03

Glossary:

A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
Examples:
The Endianness of a processor is mainly relevant in assembly language programming.
Explore C / C++ / C#
About.com Special Features

Stay connected and entertained with reviews on tips on the latest HDTVs, cellphones and more. More >

Easy ways to connect two computers for networking purposes. More >

  1. Home
  2. Computing & Technology
  3. C / C++ / C#

©2009 About.com, a part of The New York Times Company.

All rights reserved.