> ## Documentation Index
> Fetch the complete documentation index at: https://docs.sourcery.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Square Identity

#### Sourcery refactoring id: `square-identity`

#### Description:

Replaces cases of a variable being multiplied by itself with squaring that
variable

#### Before:

```python
def square(variable: int):
    return variable * variable
```

#### After:

```python
def square(variable: int):
    return variable**2
```

#### Explanation:

This identity can make the code slightly shorter and easier to read.
