Variables
Similar to other programming and scripting languages, AMPscript supports variables. In programming, variables provide a convenient method of setting a function or value once, then reusing that variable by referencing it within code. This is in much the same way that Cascading Style Sheets (CSS) classes are defined once and then the defined style properties are applied to one or more elements by including the class name in a class attribute. However, variables not only allow fixed values (or constants) to be defined once, but also AMPscript functions, and in turn, the output value of the variable can change depending on the context for which it’s interpreted.