7 ms·
The yield keyword is optional. The result is a List<HtmlElement> I don’t see how this can be done in Python without using mutation, which makes code scattered
by pharmakom 4y ago
The yield keyword is optional. The result is a List<HtmlElement>
I don’t see how this can be done in Python without using mutation, which makes code scattered across multiple statements
- snowpid 4y agoyour example has also multiply statements. The question is more important: Which syntax to a more generally better readability. (as this is solvable in most languages)
- pharmakom 4y agoNo, it is built from pure expressions. This means that our list is defined in one block (everything within the [ ] tokens) and immutability is enforced by the compiler.