We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 68bf80d commit edbcfe0Copy full SHA for edbcfe0
iostream.stdio.md
@@ -241,8 +241,6 @@ int main() {
241
242
> 小贴士:如果在多线程中并行 `<<` 输出到 cout,可能会出现黏行现象,这是因为每一条单独的 `<<` 操作是原子的(cout 是自带锁的同步流),而连续多条 `<<` 之间并不,即使是同一行上写的连续 `<<` 也不行,原因分析和解决方案见 ^[thread.osyncstream]。
243
244
-### 不推荐 `std::endl`
245
-
246
## 输入流
247
248
`std::cin` 是标准输入流,只读。对应于 C 语言的 `stdin` ^[cstdio.stdio]。
@@ -307,6 +305,8 @@ $ 1 2
307
305
308
306
`std::cout` 和 `std::clog` 输出流具有行缓冲 ^[iostream.buf]。
309
+TODO
+
310
### `std::cerr` 与 `std::clog` 的区别
311
312
`std::cerr` 禁用了行缓冲,每次 `<<` 后都会自动强制刷新缓冲区 (flush buffer)。
@@ -321,6 +321,10 @@ $ 1 2
321
322
关于输出流的缓冲与刷新机制,以及关闭输出缓冲的方法,参见 ^[iostream.buf]。
323
324
+### 不推荐 `std::endl`
325
326
327
328
## 重定向
329
330
### 输入流重定向
0 commit comments