Draw a circle in c program , C/C++ Programming

Draw a circle in c program:

void main()

{

clrscr();

int i,r=50,t,j,x,y;

int gd,gm;

gd =DETECT;

initgraph(&gd,&gm,"");

for(x=50;x<=150;x++)

for(y=50;y<=150;y++)

{

  if((x-100)*(x-100) +(y-100)*(y-100) <=2510&&x*x+y*y>=2490)

putpixel(x,y,10);

delay(1);

}

getch();

}

 

 

Posted Date: 10/18/2012 6:35:23 AM | Location : United States







Related Discussions:- Draw a circle in c program , Assignment Help, Ask Question on Draw a circle in c program , Get Answer, Expert's Help, Draw a circle in c program Discussions

Write discussion on Draw a circle in c program
Your posts are moderated
Related Questions
We move a high quantity of large Video files (200mb - 2 GB each) across the internet. We have a Linux server (ubuntu) hosted in a datacenter (1Gbps) operating an FTP server. Our

Class Templates In addition to function  templates, C++  also supports the  method of class templates. By definition, a class template is a class definition that explains a fam

How to use HTTP Headers inside PHP? Write the statement through which it can be added? HTTP headers can be used in PHP by redirection that is written as: Headers can be

ABC Car Dealership needs your help to update the ordering system. This car dealer is selling four types of vehicles: Sedan, Truck, SUV, and mini Van. And each type of vehicle can h

C program to demonstrate call by reference: void disp(int *,int*,int*,int*); void main() {                 int a=2,b=3, sum,mul;                 printf("Enter 1st n

program that convert take decimal digit and convert it to binart digit

A: The procedure of encoding the parameter types along with the function/method name into a unique name is called as name mangling. The inverse procedure is called demangling. F

Write a simple generic version of method isEqualTo that compares its two arguments with the equals method and returns true if they are equal and false otherwise. Use this generic m

Operation on array: void Array::add( Object& toAdd ) {     lastElementIndex++;     while( ptrAt( lastElementIndex ) != ZERO &&            lastElementIndex

Rules of function: Inline function created without prototype it reduces the memory and it is used only for small function. Inline function cannot have recursion, static var