Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

We can draw a box in cprogram by using only one printf();&
without using graphic.h header file?

Answer Posted / penchalaiahdinesh

There is another method to print a box without using
graphic.h
using Ascii values

You can see ascii values by running following program..

#include<stdio.h>
#include<conio.h>
main()
{
int i;
clrscr();
for(i=0;i<=255;i++)
printf("%d %c\t",i,i);
getch();
}

The below are the program to print a clear box
#include<stdio.h>
#include<conio.h>
main()
{
int i=218,j,k=1;
clrscr();
printf("%c",i);
x:i=196;
for(j=1;j<=10;j++)
printf("%c",i);
if(k==2)
goto y;
i=191;
printf("%c\n%c %c\n%c",i,179,179,192);
if(k==1)
{k=2;goto x;}
y:printf("%c",217);
getch();
}

Just this and reply me........

Is This Answer Correct ?    5 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain the use of 'auto' keyword in c programming?

1066


The statement, int(*x[]) () what does in indicate?

1079


What would happen to X in this expression: X += 15; (assuming the value of X is 5)

1881


Which are low level languages?

1041


A character flag or control mechanism that delineates one data item from another a) variable b) constant c) delimiter d) call by reference

1043


How can I change their mode to binary?

1050


Is there any algorithm to search a string in link list in the minimum time?(please do not suggest the usual method of traversing the link list)

2243


write a program to copy the string using switch case?

2841


a way in which a pointer stores the address of a pointer which stores the value of the target value a) reference b) allocation c) multiple indirection d) none

1087


Explain what is output redirection?

1133


Why is %d used in c?

956


Should a function contain a return statement if it does not return a value?

1010


Which control loop is recommended if you have to execute set of statements for fixed number of times?

1297


What is 2c dna?

1013


What are disadvantages of C language.

1100