SwikiCodeRobot @> 286 |
"many instances in a list" | count item array | count := 1000. array :=#(). self print:nil;print: #started. self print: 'Time spent allocating ',count,' instances took ',[ count timesRepeat: [ item := ArrayList instance. item handle notNil ifTrue: [ array add: item ] ]. self print: 'array size=',array size,' last=',array last. ] ms,'ms.'.