标签云

微信群

扫码加入我们

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?

2018年09月26日25分11秒

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!

2018年09月27日25分11秒

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

2018年09月26日25分11秒