:: Home Page            
 Advertise your Business Here     
Browse  |   Placement Papers  |   Company  |   Code Snippets  |   Certifications  |   Visa Questions
Post Question  |   Post Answer  |   My Panel  |   Search  |   Articles  |   Topics  |   ERRORS new
   Refer this Site  Refer This Site to Your Friends  Site Map  Bookmark this Site  Set it as your HomePage  Contact Us     Login  |  Sign Up                      
Categories >> Software >> Programming Languages >> C


 C interview questions  C Interview Questions (2266)
 C++ interview questions  C++ Interview Questions (1121)
 VC++ interview questions  VC++ Interview Questions (342)
 Delphi interview questions  Delphi Interview Questions (510)
 Programming Languages AllOther interview questions  Programming Languages AllOther Interview Questions (651)
what is the use of getch() function in C program..
difference b/w getch() and getche()??
 Question Submitted By :: C
I also faced this Question!!     Answer Posted By  
# 1
getch() is for waiting the o/p screen til we enter the inputs 
Is This Answer Correct ?    258 Yes 63 No
# 2
getch() waits for the user to input a character and
displays the output till the user enters a character.As
soon as the user enters a character it transfers the
control back to the main function, without displaying what
character was entered.
getche() does the same thin but it displays the chacter e stands for echo.
Is This Answer Correct ?    177 Yes 22 No
# 3
getch() returns to the program after hitting any key.
getche() waits for the character, read it and then returns
to the program
Is This Answer Correct ?    95 Yes 30 No
# 4
getch() is used to wait the execution of program on console
unless program will skeep the output witout showing on
console of program in short it all time to user to see
output during the run time of program
Is This Answer Correct ?    34 Yes 15 No
Sachin Banaya
# 5
getch() is used to read the character,
but getche()is used to read and display character on output.
Is This Answer Correct ?    47 Yes 31 No
# 6
getch() helps in holding the console screen and helps in reading the codes properly 
Is This Answer Correct ?    12 Yes 5 No
# 7
# 3 getch() returns to the program after hitting any key.
getche() waits for the character, read it and then returns
to the program
Is This Answer Correct ?    20 Yes 14 No
Sudhir Tiwari
# 8
getch() and getche()
both are getting input charecter to user
but getche() display the that charecter to screen
Is This Answer Correct ?    8 Yes 3 No
# 9
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.....
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 ?    6 Yes 1 No
# 10
Waiting the input for output screen.. 
Is This Answer Correct ?    5 Yes 1 No
Rajesh Kumar

Other C Interview Questions
  Question Asked @ Answers
how to print this sereis 2 4 3 6 5..........?   2
What are advantages and disadvantages of recursive calling ? HP 11
what does ‘#include’ mean? TCS 1
Determine the code below, tell me exactly how many times is the operation sum++ performed ? for ( i = 0; i < 100; i++ ) for ( j = 100; j > 100 - i; j--) sum++; ITCO 5
how to find a 5th bit is set in c program IBM 4
difference between malloc and calloc Wipro 3
how to exchnage bits in a byte b7<-->b0 b6<-->b1 b5<-->b2 b4<-->b3 please mail me the code if any one know to Honeywell 3
control 50 devices which has 2 states on and off.using bitwise operator.plz answer it its urgent   1
What's wrong with the call "fopen ("c:\newdir\file.dat", "r")"?   1
write a C program:There is a mobile keypad with numbers 0-9 and alphabets on it. Take input 0f 7 keys and then form a word from the alphabets present on the keys. Subex 1
what is the diff between the printf and sprintf functions?? and what is the syntax for this two functions ??   5
What is the Difference between Macro and ordinary definition? Motorola 3
For more C Interview Questions Click Here 

Copyright Policy  |  Terms of Service  |  Articles  |  Site Map  |  RSS Site Map  |  Contact Us
Copyright © 2013  All Rights Reserved.   ::