【题目】:Press any key to change color, do you want to try it. Please hurry up!
1.程序分析:
2.程序源代码:
1.程序分析:
2.程序源代码:
#include <conio.h>
void main(void)
{
int color;
for (color = 0; color < 8; color++)
{
textbackground(color); //设置文本的背景颜色,这个只能在TC上实现,VC6.0是不识别的
cprintf("This is color %d\r\n", color);
cprintf("Press any key to continue\r\n");
getch();/*输入字符看不见*/
}
}