📄 borc.c
字号:
#include <stdio.h>
#include <conio.h>
#include <ctype.h>
void main()
{
int x=0;
char c;
while(x<5)
{
x++; //loop counter
printf("\n%i: Press B to break, C to continue:",x);
c=toupper(getch()); //getkey
if(c=='C')
{
putchar(c); //dislay C
continue; //loop repeats right here!
}
if(c=='B')
break; //loop breaks right here!
printf("%c is not B or C.",c);
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -