#include<graphics.h>
#include<conio.h>
int main()
{
int gd = DETECT, gm;
int x1=50,y1=50,x2=200,y2=100;
initgraph(&gd, &gm, "C:\\TC\\BGI");
setcolor(9);
line(x1,y1,x2,y2);
getch();
closegraph();
return 0;
}
here's my code in drawing a simple line in C . but it has errors it said that "undefined symbol _closegraph in module LINE.cpp (LINE is the name of the program)
symbol _line in module LINE.cpp
symbol _setcolor in module LINE.cpp
*i cant figure out what's wrong with my code , pls help tnx :D