Function
choose
(lst: T[]): TChoose a random item from a list.
param
lst- The list to choose from.
// decide the best fruit randomly
const bestFruit = choose(["apple", "banana", "pear", "watermelon"]);
returns
A random item from the list.
since
v3001.0
group
Random