#include <conio.h> //控制台输出函数头文件,#include <stdio.h>int main(){int key; key = getch();while( key != 27 ) //键入值不为ESC{printf("%d\n", key);key = getch();}}