factor

Returns an array of the prime factors of an integer sorted from smallest to largest.

Syntax

factor(value)

Parameters

Return value

An array of the prime factors of the value.

Examples

factor(65535)
[3, 5, 17, 257]