## With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

No credit card required

# Calculating with Numeric Variables

## Using Arithmetic Operators in Assignment Statements

One way to perform calculations on numeric variables is to write an assignment statement using arithmetic operators. Arithmetic operators indicate addition, subtraction, multiplication, division, and exponentiation (raising to a power). For more information about arithmetic expressions, see the discussion in SAS Language Reference: Concepts.
The following table shows operators that you can use in arithmetic expressions.
Table 8.1 Operators in Arithmetic Expressions
Operation
Symbol
Example
+
x = y + z;
subtraction
x = y - z;
multiplication
*
x = y * z
division
/
x = y / z
exponentiation ...

## With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

No credit card required