Files
XCTerminal/node_modules/node-pty/deps/winpty/misc/Win32Echo2.cc
2026-03-21 20:26:20 +08:00

20 lines
307 B
C++

/*
* A Win32 program that reads raw console input with getch and echos
* it to stdout.
*/
#include <stdio.h>
#include <conio.h>
int main()
{
int count = 0;
while (true) {
int ch = getch();
printf("%02x ", ch);
if (++count == 50)
break;
}
return 0;
}