To give a variable its first value. This may be done automatically by some languages or it may require explicit code by the programmer. Some languages allow initialisation to be combined with variable definition, e.g. in C:
int i = 0;Failing to initialise a variable before using it is a common programming error, but one which compilers and automatic checkers like lint can easily detect.
Last updated: 1997-06-08