> For the complete documentation index, see [llms.txt](https://www.unrealsharp.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://www.unrealsharp.com/data-and-asset-management/collections/tarray.md).

# TArray

Example of setting up an array and adding to it.

```csharp
[UClass]
public partial class AMyShowcaseClass : AActor
{ 
    [UProperty(PropertyFlags.EditAnywhere | PropertyFlags.BlueprintReadWrite)]
    public partial TArray<int> Array { get; set; }

    public override void BeginPlay()
    {
        base.BeginPlay();

        Array.Add(1);
    }    
}
```

TArray can also be represented as an IList inside of a UFunction

```csharp
[UFunction(FunctionFlags.BlueprintCallable)]
public void TestList(IList<string> myList)
{
    PrintString($"List Count: {myList.Count}");
}
```
