
Добавил:
korayakov
Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз:
Предмет:
Файл:Лупин / Лабы.МП.-.5.семестр.Операционные.Системы.2007 / Лабы / lab4 / LAB41
.CPP#include "stdio.h"
#include "conio.h"
#include "stdlib.h"
#include "process.h"
#include "dos.h"
#include "graphics.h"
#include "iostream.h"
#include "io.h"
void main()
{char sm[20];
int midx, midy;
textmode(BW80);
int mode=DETECT, driver=EGA;
initgraph(&driver, &mode, "c:\\BORLANDC\\bgi");
int errorcode = graphresult();
if (errorcode != grOk)
{
printf("Graphics error: %s\n", grapherrormsg(errorcode));
printf("Press any key to halt:");
getch();
exit(1);
};
midx = getmaxx() / 2;
midy = getmaxy() / 2;
cout << "Input Name Surname: " << endl;
scanf("%s", sm);
setcolor(4);
setbkcolor(1);
settextjustify(CENTER_TEXT, CENTER_TEXT);
outtextxy(midx, midy, sm );
getch();
closegraph();
}
Соседние файлы в папке lab4