---
url: /cube-functions/xor.md
description: Returns 1 or 0 based on two or more conditions.
---

# XOR&#x20;

Returns 1 or 0 based on two or more conditions.

```js
XOR(condition_a, ...condition_n)
```

#### Parameters

* `condition_a` - Condition to be evaluated.
* `condition_n` - Condition to be evaluated. `(optional)`

#### Examples

```js
XOR(1 = 1, 2 = 3)
```

**Result:** `1`

```js
XOR(1 = 1, 2 = 2)
```

**Result:** `0`
