include <conio.h>
void main(void)
{
clrscr();/*清屏函数*/
textbackground(2);
clrscr函数为C语言的清屏函数,功能为清除屏幕上的输出,clrscr为clear screen的简写。
gotoxy(1, 5);/*定位函数*/
功能:将光标移动到指定位置
说明:
gotoxy(x,y)中
参数x为移动到位置的横坐标;
参数y为移动到位置的纵坐标。
gotoxy()函数没有返回值。
cprintf("Output at row 5 column 1\n");
textbackground(3);
gotoxy(20, 10);
cprintf("Output at row 10 column 20\n");
}
小白每天学习两个函数D1-(clrscr,gotoxy)
最新推荐文章于 2023-08-29 16:08:36 发布