Returns the concatentation of x with its own duplicate in reverse order. If input is an iterable, it MUST be finite!
x
In the general case, this is similar to concat(x, reverse(x)), though keeps input type intact.
concat(x, reverse(x))
palindrome("hello"); // "helloolleh" palindrome([1, 2, 3]); // [1, 2, 3, 3, 2, 1] palindrome(range(3)); // IterableIterator<number>
-
Generated using TypeDoc
Returns the concatentation of
x
with its own duplicate in reverse order. If input is an iterable, it MUST be finite!In the general case, this is similar to
concat(x, reverse(x))
, though keeps input type intact.palindrome("hello"); // "helloolleh" palindrome([1, 2, 3]); // [1, 2, 3, 3, 2, 1] palindrome(range(3)); // IterableIterator<number>