
Program to draw a colored circle with a pattern
#include <graphics.h>
#include <conio.h>
void main()
{
int d,m;
int midx,midy;
d=DETECT;
initgraph(&d,&m,"c:\\tc\\bgi");
midx=getmaxx()/2;
midy=getmaxy()/2;
setfillstyle(6,2);
circle(midx,midy,50);
floodfill(midx,midy,15);
getch();
closegraph();
}
Output :

0 comments:
Post a Comment