随笔分类 -  程序性能

如何写出执行效率高的程序?
摘要:You can get the free vesion in the website: http://www.jetbrains.com/profiler/. 阅读全文
posted @ 2013-01-28 10:58 nchxmoon 阅读(141) 评论(0) 推荐(0)
摘要:很多时候,我们在选择循环的时候,会考虑用那个循环好一点,这个好一点就是指效果高一点!今天我对于for, foreach循环做了个性能测试,测试代码如下:// Performance test of for loop. private void ForLoopPerformance() { System.Diagnostics.Debug.WriteLine("ForLoopPerformance: ");string[] array = new string[10000000];DateTime d1 = DateTime.Now; for (int i = 0; i &l 阅读全文
posted @ 2012-12-31 17:32 nchxmoon 阅读(12902) 评论(1) 推荐(0)