3 ms·
> What's missing here is an Ienumerable from c#. That's basically anything that can be iterated like a list. So a function could take this enumerable and conver
by collinmanderson 4y ago
> What's missing here is an Ienumerable from c#. That's basically anything that can be iterated like a list. So a function could take this enumerable and convert it to a list but should probably reject everything else.
Python has an Iterable type class for this.
https://docs.python.org/3/library/typing.html#nominal-vs-structural-subtyping https://docs.python.org/3/library/typing.html#nominal-vs-str...
https://docs.python.org/3/library/collections.abc.html#collections.abc.Iterable https://docs.python.org/3/library/collections.abc.html#colle...