Tech Talk About C++ and C
Comeau C++ and C FAQ

Copyright © 2000-2014 Comeau Computing. All rights reserved. Note that this is a live web page, in the sense that we'll be adding new discussions as appropriate (we probably have 5 or so more topics already planned), so stop by from time to time. This web page is also under construction (Version 1.20, December, 2014), so if you see something not right, please email us about it.

As well, take a look at our Other FAQs, the Comeau Templates FAQ and the the Comeau C99 FAQ

The intent of this page is to address questions about C++ and C that come up often, perhaps too often. However, it is exactly the frequency of these topics that is the reason for including a discussion of them below. These issues usually come up as having originated from a misleading statement commonly made, or from code shown in a book. These points have found themselves here as the result of our connection to the C++ and C communities for 20 years, whether teaching, helping in newsgroups, providing tech support for Comeau C++, or just plain listening to folks' issues. Some of the topics below can be found in other FAQs, however, here we try to offer more information on the respective topics, as well as issues related to them. Here's the current topics:

  1. What book do you recommend?
  2. Where is the FAQ for the various C and C++ newsgroups?
  3. Can I really get the C++ Standard electronically for $18?
  4. Can I get Standard C electronically too?
  5. What's wrong with code that uses void main()?
  6. What about returning from main()?
  7. Where does the int returned from main() go?
  8. What's the difference between endl and '\n'?
  9. Why can't I fflush(stdin), or any input stream??
  10. How do I remove all chars from a stream??