Курсовая работа: Поиск в лабиринте
fread(&ch, sizeof(ch), 1, f);
//Chitat' final'nuyu pozitciu:Y
fread(&ch,sizeof(ch), 1, f);
finish.y = atoi(&ch);
fread(&ch, sizeof(ch), 1, f);
}
void tLabirint::Find()
{
GetCoords();
DFS();
if(flag==0)
outtextxy(20, 440, "No way!");
else
outtextxy(20, 440, "Found way!");
}
void main()
{
tLabirint *lab;
clrscr();
lab = new tLabirint();
lab->ReadMatrix();
lab->DrawLabirint();
lab->Find();
/**/
getch();
delete lab;
}