Ads

CIRCLE ILLUSION IN C PROGRAMMING | C GRAPHICS PROGRAMMING | C++ PROGRAMMING

 



//____________WELCOME ALL OF YOU ON ROHIT TECH STUDY CHANNEL_______________//

//_____________>>>>>> C PROGRAM TO DRAW CIRCLE ILLUSION <<<<<<<____________//


#include<conio.h>

#include<stdio.h>

#include<graphics.h>

#include<stdlib.h>

#include<dos.h>

void main()

{

float i=0.1;

int j=0,gd=DETECT,gm,x,y;

initgraph(&gd,&gm,"C:\\TC\\BGI");

x=getmaxx()/2;

y=getmaxy()/2;

while(!kbhit())

{

setcolor(rand()%16);

arc(x,y,1+j,2+j,i+=0.1);

delay(10);

j++;

}

getch();

closegraph();

}


Post a Comment

0 Comments