By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
431,965 Members | 2,043 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 431,965 IT Pros & Developers. It's quick & easy.

what is difference between getch() and getchar() in c language ?

P: 1
what is difference between getch() and getchar() in c language ?
Dec 17 '10 #1
Share this Question
Share on Google+
2 Replies


100+
P: 1,059
did you tried program and see. Its crystal clear you write a simplest program.

if your compiler dont support conio.h in that case it would be hard to know
Dec 17 '10 #2

Expert 100+
P: 2,398
getchar is a Standard Library function (part of stdio.h). It is supported on all platforms.

getch is not part of the Standard (it is part of conio.h). Code that uses getch is nonportable.

For functional differences you should search for the man pages for stdio.h and conio.h.
Dec 17 '10 #3

Post your reply

Sign in to post your reply or Sign up for a free account.