


1/11/00
COM1100
Winter2000 Yuhong Yin Northeastern University
Variable
nAll integers,
floating-points, strings and other values used in a program
are stored in and retrieved from the memory unit.
Conceptually, individual memory locations in the memory unit
are arranged like the rooms in a large hotel. Like hotel
rooms, each memory location has a unique address (“room number”).
n
n A variable is simply a
name (or an identifier) chosen by the programmer that is used to refer to computer storage location. The
term variable is used because the value stored in the
variable can change, or vary.
n