📜  c# 读取单键 - C# 代码示例

📅  最后修改于: 2022-03-11 14:48:51.095000             🧑  作者: Mango

代码示例1
Console.WriteLine("Enter any Key: ");
ConsoleKeyInfo name = Console.ReadKey();
Console.WriteLine("You pressed {0}", name.KeyChar);