Warning: file_get_contents(/data/phpspider/zhask/data//catemap/6/cplusplus/154.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
C++ 回车c++\r和\b输出_C++_Carriage Return - Fatal编程技术网

C++ 回车c++\r和\b输出

C++ 回车c++\r和\b输出,c++,carriage-return,C++,Carriage Return,有人能解释一下下面的输出吗 我不明白为什么以下语句的输出: printf("\n Hello"); printf("\b world"); printf("\r Cup"); 是: 让我们使用|作为运输工具: 在“\n”之后:| 在“你好”之后:Hello | 在“\b”之后:Hell | 在“世界”之后:地狱世界| 在“\r”之后:|地狱世界 在“杯”之后:Cup|l world让我们用作为运输工具: 在“\n”之后:| 在“你好”之后:Hello | 在“\b”之后:Hell | 在“世界

有人能解释一下下面的输出吗

我不明白为什么以下语句的输出:

printf("\n Hello");
printf("\b world");
printf("\r Cup");
是:


让我们使用
|
作为运输工具:

在“\n”之后:
|

在“你好”之后:
Hello |

在“\b”之后:
Hell |

在“世界”之后:
地狱世界|

在“\r”之后:
|地狱世界


在“杯”之后:
Cup|l world
让我们用
作为运输工具:

在“\n”之后:
|

在“你好”之后:
Hello |

在“\b”之后:
Hell |

在“世界”之后:
地狱世界|

在“\r”之后:
|地狱世界

“杯赛”后:
Cup|l world

 Cupl world