标签云

微信群

扫码加入我们

WeChat QR Code


So ion a tight loop, it would be much better to use add range so not as to lose performance due to all the internal newing and pounding the GC?

2019年02月22日57分48秒

Actually, due to deferred execution, using Concat would likely be faster because it avoids object allocation - Concat doesn't copy anything, it just creates links between the lists so when enumerating and you reach the end of one it transparently takes you to the start of the next!

2019年02月23日57分48秒

+1, Indeed, if you forget to 'tolist', concat silently does nothing

2019年02月22日57分48秒