🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

fputc

Started by
1 comment, last by frob 6 months, 2 weeks ago

Does anyone know why fputc takes an integer instead of a character?

Here is the prototype:

int fputc(int char, FILE *stream)

Thank you.

Mike C.http://www.coolgroups.com/zoomer/http://www.coolgroups.com/ez/
Advertisement

So it can take the output of fgetc(). Also probably a carry-over from the 1970s and the default int parameters from the earliest days of C.

This topic is closed to new replies.

Advertisement