#include < stdio.h >
#include < graphics.h >
#include< stdlib.h >
#include< conio.h >
void main()
{
int gm,x,y,gd=DETECT,i;
// int midx, midy;
int stangle = 45, endangle = 50;
int radius = 50;
initgraph(&gd,&gm,"z:\\tc\\bgi");
x=getmaxx();// to get the co-ordinates i.e. x & y
y=getmaxy();
cleardevice();
fflush(stdout);// this is the function in c to clean the screen
line(200,150,350,150);
line(140,200,200,150);
line(140,330,140,200);
line(250,200,140,200);
line(200,150,250,200);
circle(196,180,15);
setfillstyle(2,14);
floodfill(196,180,15);
setfillstyle(1,2);
line(350,150,400,200);
floodfill(210,180,15);
line(400,200,400,330);
line(140,330,400,330);
line(250,200,250,330);
line(250,200,400,200); // Hut
setfillstyle(5,7);
floodfill(260,180,15);
line(170,260,170,330);
line(170,260,210,260);
setfillstyle(10,9);
floodfill(180,250,15);
line(210,260,210,330);
setfillstyle(9,9);
floodfill(210,250,15);
line(290,110,290,150);
line(310,110,310,150);
ellipse(300,110,0,360,10,3); // Chemney
setfillstyle(6,8);
floodfill(300,120,15);
line(300,250,350,250);
line(300,280,350,280);
line(300,250,350,280);
line(300,280,300,250);
line(350,280,350,250);
setfillstyle(9,9);
floodfill(252,300,15);
setfillstyle(8,9);
floodfill(342,270,15);
// midx = getmaxx() /4 ;
// midy = getmaxy() /4 ;
// setcolor(getmaxcolor());
setcolor(2);
/* draw arc */
arc(30,300,stangle, endangle, radius);
setcolor(8);
line(5,330,600,330);
for(i=0;i<650;i=i+10)
{
setcolor(4);
settextstyle(7,0,5);
outtextxy(0+i,390,"Home Sweet Home");
delay(100);
setcolor(0);
settextstyle(7,0,5);
outtextxy(0+i,390,"Home Sweet Home");
}
getch();
closegraph();
}
hey i m going to give a program that accepts edges a input and then it draws the graph using a computer graphics display...
write a sample program using asp.net explaining all the syntax and semantics of the program
write a vb program to find the magic square
Write and run a client and a server program in C-language using UDP
write a c++ program to convert binary number to decimal number by using while statement
write a program that reads a phrase and prints the number of lowercase latters in it using a function for counting? in C program
write a c++program by using if statement to read a number and check whether it is positive or negative
program to find maximum of two numbers using pointers
here you go nah...
Write a program to find the grade obtained by the students of a class
abdulrahman
#include<