cout 和cerr的区别
来源:互联网 发布:gene ontology数据库 编辑:程序博客网 时间:2024/06/06 01:24
总结了一下,主要有几点,欢迎指正。
1、cout对应于标准输出流
cerr对应于标准错误流
2、cout可以重定向,cerr不可以。
3、cout要分配缓冲,cerr不用,所以从理论上来说,cerr输出要比cout要快。
4、cout和cerr默认都是标准输出设备:显示器.
英文表述是:
cout:
The cout object corresponds to the standard output stream. By default, this stream is associated with the standard output device, typically a monitor. The wcout object is similar but works with the wchar_t type.
cerr:
The cerr object corresponds to the standard error stream, which you can use for displaying error messages. By default, this stream is associated with the standard output device, typically a monitor, and the stream is unbuffered. This means that information is sent directly to the screen, without waiting for a buffer to fill or for a newline character. The wcerr object is similar but works with the wchar_t type.
- cout 和cerr的区别
- cout和cerr的区别
- cerr和cout的区别
- c++中cerr和cout的区别
- c++中cerr和cout的区别
- C++中cout和cerr的区别?
- C++中cout和cerr的区别
- C++中cout和cerr的区别?
- C++中cout和cerr的区别?
- C++中cout和cerr的区别?
- C++中cout和cerr的区别?
- c++中cout和cerr的区别
- C++中cout和cerr的区别
- C++中cout和cerr的区别?
- cerr、clog、cout的区别
- cerr与cout的区别
- cerr与cout的区别
- cerr与cout的区别
- Geronimo 叛逆者: 直面 JSF
- Java中Uuid的实现
- 并行启动应用程序从而加速 Linux 的引导
- lucene中主要用到的类
- 整合 JSF+Spring+Hibernate的小例子
- cout 和cerr的区别
- Window.Open详解
- 经典脚本
- Java字符集转换解释
- javascript刷新
- 文件名批量修改多法
- 更改安装包中的图标
- ASP.NET 防盗链源码
- QTP: Get Data as Collection