A bit can be stored by a digital device or other physical system that exists in either of two possible distinct
states. These may be the two stable states of a
flip-flop, two positions of an
electrical switch, two distinct
voltage or
current levels allowed by a
circuit, two distinct levels of
light intensity, two directions of
magnetization or
polarization, the orientation of reversible double stranded
DNA, etc. Perhaps the earliest example of a binary storage device was the
punched card invented by
Basile Bouchon and Jean-Baptiste Falcon (1732), developed by
Joseph Marie Jacquard (1804), and later adopted by
Semyon Korsakov,
Charles Babbage,
Herman Hollerith, and early computer manufacturers like
IBM. A variant of that idea was the perforated
paper tape. In all those systems, the medium (card or tape) conceptually carried an array of hole positions; each position could be either punched through or not, thus carrying one bit of information per potential hole location. The encoding of text by bits was also used in
Morse code (1844) and early digital communications machines such as
teleprinters (1870). The first electrical devices for discrete logic (such as
elevator and
traffic light control
circuits,
telephone switches, and Konrad Zuse's computer) represented bits as the states of
electrical relays which could be either "open" or "closed". These relays functioned as mechanical switches, physically toggling between states to represent binary data, forming the fundamental building blocks of early computing and control systems. When relays were replaced by
vacuum tubes, starting in the 1940s, computer builders experimented with a variety of storage methods, such as pressure pulses traveling down a
mercury delay line, charges stored on the inside surface of a
cathode ray tube, or opaque spots printed on
glass discs by
photolithographic techniques. In the 1950s and 1960s, these methods were largely supplanted by
magnetic storage devices such as
magnetic-core memory,
magnetic tapes,
drums, and
disks, where a bit was represented by the polarity of
magnetization of a certain area of a
ferromagnetic film, or by a change in polarity from one direction to the other. The same principle was later used in the
magnetic bubble memory developed in the 1980s, and is still found in various
magnetic strip items such as
metro tickets and some
credit cards. In modern
semiconductor memory, such as
dynamic random-access memory or a
solid-state drive, the two values of a bit are represented by two levels of
electric charge stored in a
capacitor or a
floating-gate MOSFET. In certain types of
programmable logic arrays and
read-only memory, a bit may be represented by the presence or absence of a conducting path at a certain point of a circuit. In
optical discs, a bit is encoded as the presence or absence of a
microscopic pit on a reflective surface. In one-dimensional
bar codes and two-dimensional
QR codes, bits are encoded as lines or squares which may be either black or white. In modern digital computing, bits are transformed in Boolean
logic gates.
Transmission and processing Bits are transmitted one at a time in
serial transmission. By contrast, multiple bits are transmitted simultaneously in a
parallel transmission. A
serial computer processes information in either a bit-serial or a byte-serial fashion. From the standpoint of data communications, a byte-serial transmission is an 8-way parallel transmission with binary signalling. In programming languages such as
C, a
bitwise operation operates on binary strings as though they are vectors of bits, rather than interpreting them as
binary numbers. Data transfer rates are usually measured in decimal SI multiples. For example, a
channel capacity may be specified as 8 kbit/s = 1 kB/s.
Storage File sizes are often measured in (binary) IEC multiples of bytes, for example, 1 KiB = 1024 bytes = 8192 bits. Confusion may arise in cases where (for historic reasons) file sizes are specified with binary multipliers using the ambiguous prefixes K, M, and G rather than the IEC standard prefixes Ki, Mi, and Gi. Mass storage devices are usually measured in decimal SI multiples, for example, 1 TB = 10^{12} bytes. Confusingly, the storage capacity of a directly addressable memory device, such as a
DRAM chip, or an assemblage of such chips on a memory module, is specified as a binary multiple—using the ambiguous prefix G rather than the IEC recommended Gi prefix. For example, a DRAM chip that is specified (and advertised) as having
1 GB of capacity has 2^{30} bytes of capacity. As of 2022, the difference between the popular understanding of a memory system with
8 GB of capacity and the SI-correct meaning of
8 GB was still causing difficulty to software designers. == Unit and symbol ==