Algosim documentation: ToSet

ToSet

Converts an object to a set.

Syntax

Description

If X is any object, then ToSet(X) returns a set with the same content as X, to the extent it is possible.

Examples

ToSet(IdentityMatrix(100))
{1, 0}
pm ≔ ColorGradient(100, 100, "red", "black");
'(#pm, #ToSet(pm))
10000
100
s ≔ "I suspect nargles are behind it."; ToSet(s)
{s, c, u, a, I, n, g, d, t, r, ., i, h, b, p,  , e, l}

See also