[lang-ref] ( set_to_array ) ( python )
def test_set_to_array():
# list(s)
s = { "b", "a", "c", "d", "e" }
items = list(s) # the order is not guaranteed
actual = [ "a", "b", "c", "d", "e" ]
assert sorted(items) == actual
def test_set_to_array():
# list(s)
s = { "b", "a", "c", "d", "e" }
items = list(s) # the order is not guaranteed
actual = [ "a", "b", "c", "d", "e" ]
assert sorted(items) == actual