System.Environment

1、获取命令行参数
string[] args = Environment.GetCommandLineArgs();
2、获取本地驱动器信息
string[] derives = Environment.GetLogicalDerives();
3、获取进程数
Environment.ProcessorCount;


原文地址:https://www.cnblogs.com/handongdong/p/2211442.html