# /= assignment operator

The /= assignment operator divides a
variable by a numeric expression and assigns it to the given variable.

## Syntax

```
var /= num.exp
```

## Example(s)

This divides the current value
of `x` by `2` and assigns the result
to `x`. It is equivalent to: `x = x / 2`

```
x /= 2
```

## See also

- [* arithmetic operator](https://d3codex.com/pickbasic-flashbasic/asterisk-arithmetic-operator/)
- [*= assignment operator](https://d3codex.com/pickbasic-flashbasic/asterisk-equals-assignment-operator/)
- [+= assignment operator](https://d3codex.com/pickbasic-flashbasic/plus-equals-assignment-operator/)
- [- arithmetic operator](https://d3codex.com/pickbasic-flashbasic/minus-arithmetic-operator/)
- [-= assignment operator](https://d3codex.com/pickbasic-flashbasic/minus-equals-assignment-operator/)
- [:= assignment operator](https://d3codex.com/pickbasic-flashbasic/colon-equals-assignment-operator/)
- [Arithmetic expressions](https://d3codex.com/pickbasic-flashbasic/arithmetic-expressions/)
- [Arithmetic operators](https://d3codex.com/pickbasic-flashbasic/arithmetic-operators/)
- [Assignment](https://d3codex.com/pickbasic-flashbasic/assignment/)
- [Numeric expressions](https://d3codex.com/pickbasic-flashbasic/numeric-expressions/)
- [Precedence](https://d3codex.com/pickbasic-flashbasic/precedence/)
- [precision statement](https://d3codex.com/pickbasic-flashbasic/precision-statement/)
- [Relational operators](https://d3codex.com/pickbasic-flashbasic/relational-operators/)
- [sum() function](https://d3codex.com/pickbasic-flashbasic/sum-function/)
- [\= assignment operator](https://d3codex.com/pickbasic-flashbasic/backslash-equals-assignment-operator/)

---
Source: https://d3codex.com/pickbasic-flashbasic/slash-equals-assignment-operator/ - part of the D3Codex reference.
