# PI

[Constant](index.md) / **PI**

<div class="grid cards" markdown>

* :green_circle: Can Read

* :red_circle: Cannot Write

</div>

## Description

Returns the ratio of the circumference of a circle to its diameter

## Code

```cs
using System;
using UnityEngine;
using VisualScript.Icons;

namespace VisualScript.Runtime
{
    [Get]
    
    [Title("PI")]
    [Category("Constant/PI")]
    
    [Description("Returns the ratio of the circumference of a circle to its diameter")]
    [Image(typeof(IconPI), ColorTheme.Type.Yellow)]
    
    [Serializable]
    public class TypeNumberConstantPI : TypeNumber
    {
        public override double GetPreview(GameObject source) => Math.PI;

        public override double Get(Args args) => Math.PI;

        public override string ToString()
        {
            return "PI";
        }
    }
}
```

