生詞解釋:Diagnostics[,daɪəg'nɑstɪks] n.診斷學 ...
生詞解釋:Diagnostics[,daɪəg'nɑstɪks] n.診斷學
using System.Diagnostics; Stopwatch sw = new Stopwatch (); sw.Start (); string str = "a"; for (var i = 0; i < 10000; i++) { str += "b"; } sw.Stop (); Console.WriteLine (sw.Elapsed); // 輸出 從 Start() 到 Stop() 之間經過時間。(單位:秒)