what is the difference between getch() and getchar()?
Answer Posted / barath krishnan
getchar() is very similar to using scanf with %c. The getch() function is normally used in 2 cases
1 To read any character not just numbers and alphabets but any
non white space character ( any key oder dan num/caps/scroll locks or tab keys)
2 To keep reading from a stream of inputs without forcing the user to press enter key at the end of each input unlike getchar()
Is This Answer Correct ? | 7 Yes | 1 No |
Post New Answer View All Answers
What is the right type to use for boolean values in c? Is there a standard type? Should I use #defines or enums for the true and false values?
Write a program to reverse a given number in c language?
The __________ attribute is used to announce variables based on definitions of columns in a table?
How can I copy just a portion of a string?
If null and 0 are equivalent as null pointer constants, which should I use?
what is the different bitween abap and abap-hr?
What is static identifier?
if a is an integer variable, a=5/2; will return a value a) 2.5 b) 3 c) 2 d) 0
What are c identifiers?
What is putchar() function?
What are extern variables in c?
Write a program to find factorial of a number using recursive function.
Do pointers need to be initialized?
1.int a=10; 2.int b=20; 3. //write here 4.b=30; Write code at line 3 so that when the value of b is changed variable a should automatically change with same value as b. 5.
Is python a c language?