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...

what is the use of getch() function in C program..
difference b/w getch() and getche()??

Answer Posted / lekha

Both getch() and getche() are used to read single character
there is very little difference
-getch() doesn't display output to screen if used without lvalue
-getche() display output to screen even if used without lvalue

following example will clear this.....
1.
main()
{
getch();
}
2.
main()
{
getche();
}
after running above programs...............
when you press any key, you'll exit from output screen
verify the output by pressing alt+F5
1. will not show anything
2.will show the key you were pressed......
hope you get it.............

Is This Answer Correct ?    9 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain how can you determine the size of an allocated portion of memory?

1150


program to find out date after adding 31 days to a date in the month of febraury also consider the leap year

3147


What is difference between function overloading and operator overloading?

1138


Is main is user defined function?

1210


What are the disadvantages of a shell structure?

1421


write a program in c language to print your bio-data on the screen by using functions.

6839


What is an expression?

1108


How many types of operator or there in c?

1137


Which header file should you include if you are to develop a function which can accept variable number of arguments?

1462


Explain what would happen to x in this expression: x += 15; (assuming the value of x is 5)

1322


What the different types of arrays in c?

1123


Take an MxN matrice from user and then sum upper diagonal in a variable and lower diagonal in a separate variables. Print the result

1944


int i=10; printf("%d %d %d", i, i=20, i);

1696


List at least 10 sorting methods indicating their average case complexity, worst case complexity and best case complexity.

2794


How pointers are declared?

1010