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 difference between getch() and getchar()?

Answer Posted / shivani

getchar() is a function call: it reads in a single
character and waits for the user to hit 'enter key' before
reading the character. This line is included because many
compiler environments will open a new console window, run
the program, and then close the window before you can see
the output. This command keeps that window from closing
because the program is not done yet because it waits for
you to hit enter. Including that line gives you time to see
the program run.
getch() is not waiting to press enter to show output on
screen.
but getchar() is waiting to press enter to show output.

Is This Answer Correct ?    9 Yes 10 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

In C programming, how do you insert quote characters (‘ and “) into the output screen?

1482


What is the return type of sizeof?

1029


How can I change their mode to binary?

1054


What is the use of extern in c?

1050


Explain the difference between structs and unions in c?

961


Is c is a high level language?

1132


the constant value in the case label is followed by a a) semicolon b) colon c) braces d) none of the above

1199


How do I read the arrow keys? What about function keys?

1021


What is the purpose of main( ) in c language?

1093


Explain why C language is procedural?

1168


Why c is a procedural language?

1012


What is c programing language?

1047


printf(), scanf() these are a) library functions b) userdefined functions c) system functions d) they are not functions

1099


What is an auto keyword in c?

1048


What is a c token and types of c tokens?

1014