import { last } from "https://deno.land/x/ayonli_jsext@v0.9.72/array/index.ts";
Returns the last element of the array, or undefined
if the array is empty.
This function is equivalent to arr[arr.length - 1]
or arr.at(-1)
.
Parameters
arr: T[]
import { last } from "https://deno.land/x/ayonli_jsext@v0.9.72/array/index.ts";
Returns the last element of the array, or undefined
if the array is empty.
This function is equivalent to arr[arr.length - 1]
or arr.at(-1)
.