RosettaCodeData/Task/Multiple-distinct-objects/Python/multiple-distinct-objects-1.py

2 lines
73 B
Python
Raw Permalink Normal View History

2023-07-01 11:58:00 -04:00
[Foo()] * n # here Foo() can be any expression that returns a new object