What does the “c” mean in cout, cin, cerr and clog?

前端 未结 3 1905
北荒
北荒 2020-12-28 11:40

What does the "c" mean in the cout, cin, cerr and clog names?

I would say char but I haven\

3条回答
  •  爱一瞬间的悲伤
    2020-12-28 12:35

    I originally guessed console, and this link confirmed it. But after seeing the quote from Stroustrup, it seems that's a misconception, and that the c stands for character.

    One thing in favor of that theory that can serve as an indicator is the fact that for each stream object (cin, cout, cerr, etc.) there is an equivalent, wide-stream one (wcin, wcout, wcerr, etc.).

提交回复
热议问题