4 ms·
No, I think your criticism is fair. "Modeled" is not quite accurate, since the term was applied retroactively to functionality that was already implemented. St
by nemo1618 8y ago
No, I think your criticism is fair. "Modeled" is not quite accurate, since the term was applied retroactively to functionality that was already implemented.
Still, I wouldn't call the resemblance superficial. "iota" in both languages refers to sequences of whole numbers. If "iota" in Go meant "the zero-value for an arbitrary object" or "the smallest non-zero float64," then the two would truly share only a name.
- boomlinde 8y agoIf there are more than superficial similarities between the two, surely there is a rough analogue for "⍳10" in Go using its iota. Conversely there must be an analogue for "const ( A = iota; B; C )" in APL using its iota. Those are the fundamental uses of these entirely (IMO) different concepts. In the latter case, you can say that "A B C←⍳3" (at least in Dyalog) which is roughly equivalent to a Go constant assignment using iota if you squint a little and disregard the underlying procedure of creating and unpacking an array at run-time vs creating a compile-time constant. In the former case, I'm not aware of any analogue.