> For the complete documentation index, see [llms.txt](https://docs.r.xyz/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.r.xyz/glider-ide/api/variables/variable/variable.source_code.md).

# Variable.source\_code()

Returns source code of variable

`source_code() → str`

## Query Example

```python
from glider import *


def query():
  state_variables = (
    StateVariables()
    .exec(5)
  )

  print(state_variables[0].source_code())

  return state_variables
```

## Example Output

<figure><img src="https://2237101709-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FDX4Ojc4j1ef51TUAtYOx%2Fuploads%2FlZj0UkKZ1gfJPsmehktX%2Fimage.png?alt=media&amp;token=a8495b54-5025-4d89-b50d-64dc31dd4c43" alt=""><figcaption></figcaption></figure>
