|
Or like Standard ML. But it's interesting, since I hadn't seen that part yet, only the loop part and some of the dynamic typing. for List:
each i: [1, 2]
each j: ["a", "b", "c"]
[i, j]
> [[1, "a"], [1, "b"], [1, "c"], [2, "a"], [2, "b"], [2, "c"]]
for (i: 1..4):
"number " +& i
~into List
> ["number 1", "number 2", "number 3"]
for:
each:
friend: ["Alice", "Bob", "Carol"]
index: 1..4
println(index +& ". " +& friend)
1. Alice
2. Bob
3. Carol
It gave me the impression of more of a cross between Scheme and Python. |
but, I actually really like what they have going here. Seems nice and minimalist, while meeting consistent and clean.