匿名 #6347(2008/05/27 00:01 GMT) [ C++ ] Rating0/0=0.00
こんにちは。 このコードは環境に依存しています。標準ではありません。 でも、C/C++だとstdioもiosteamもブロッキングされちゃうのでこういうコード書くしか手がないと思われます。 抜け道募集。
1 2 3 4 5 6 7 8 9 10 11 12 13 14
#include <stdio.h> #include <conio.h> int main(){ bool Output=true; int ch=0; do{ ch = 0; if(_kbhit()) ch = _getch();//環境依存コード。 if(ch == 'p') Output = !Output; if(Output) printf("A"); }while(ch != 'q'); }
Rating0/0=0.00-0+
1 reply [ reply ]
匿名
#6347()
[
C++
]
Rating0/0=0.00
こんにちは。 このコードは環境に依存しています。標準ではありません。 でも、C/C++だとstdioもiosteamもブロッキングされちゃうのでこういうコード書くしか手がないと思われます。 抜け道募集。
Rating0/0=0.00-0+
1 reply [ reply ]