Write a program to draw 3 concentric circle
Answers
Answered by
2
#include<stdio.h>
#include<graphics.h>
#include<conio.h>
int main()
{
int g = DETECT,graph;
int a,b;
initgraph(&g, &graph, "C:\\TC\\BGI");
a = getmaxx()/2;
b = getmaxy()/2;
setcolor(GREEN);
circle(a, b, 30);
setcolor(BLUE);
circle(a, b, 50);
setcolor(WHITE);
circle(a, b, 70);
getch();
closegraph();
return 0;
}
Hope this helps!
#include<graphics.h>
#include<conio.h>
int main()
{
int g = DETECT,graph;
int a,b;
initgraph(&g, &graph, "C:\\TC\\BGI");
a = getmaxx()/2;
b = getmaxy()/2;
setcolor(GREEN);
circle(a, b, 30);
setcolor(BLUE);
circle(a, b, 50);
setcolor(WHITE);
circle(a, b, 70);
getch();
closegraph();
return 0;
}
Hope this helps!
Similar questions