TArray::Last

Returns n-th last element from the array. Const version of the above.

Choose your operating system:

Windows

macOS

Linux

References

Module

Core

Header

/Engine/Source/Runtime/Core/Public/Containers/Array.h

Include

#include "Containers/Array.h"

Syntax

const ElementType & Last
(
    SizeType IndexFromTheEnd
) const

Remarks

Returns n-th last element from the array.

Const version of the above.

Returns

Reference to n-th last element from the array.

Parameters

Parameter

Description

IndexFromTheEnd

(Optional) Index from the end of array (default = 0).