![]() |
|
Navigation |
Synopsis Convert a set to an indented string.
Function
str itoString(set[&T] st)
Usage
import Set;
Examples
rascal>import Set; ok rascal>toString({1, 2, 3}); str: "{1,2,3}" rascal>toString({"elephant", "zebra", "snake"}); str: "{\"snake\",\"zebra\",\"elephant\"}"
Pitfalls Recall that the elements of a set are unordered and that there is no guarantee in which order the set elements will be placed in the resulting string.
![]() |