命名空间:System.Diagnostics Stopwatch watch = new Stopwatch(); watch.Start(); watch.Stop(); Console.WriteLine(watch.ElapsedMilliseconds + "毫秒");
命名空间:System.Diagnostics Stopwatch watch = new Stopwatch(); watch.Start(); watch.Stop(); Console.WriteLine(watch.ElapsedMilliseconds + "毫秒");