doc/docs/CPlusPlus-main/03_C++的打印.md
sairate fa9377e4ae docs(book): 添加现代 C++教程及相关代码
- 新增现代 C++ 教程的 Preface 章节,包括英文和中文版本
- 添加 C++ Primer 练习代码
- 新增 Learn C++ 教程的 C++ 开发简介章节
- 添加头文件解析文档
- 更新 mkdocs.yml,包含新教程的目录结构
- 修改项目设置,使用 Python 3.10环境
2025-07-08 09:52:45 +08:00

29 lines
582 B
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# C++的打印
# 1. 打印
① cout << "XXXX" << endl; 会使得屏幕打印双引号里面的字符串
system("pause"); 会使得屏幕的打印界面暂停到该语句这里按任意键后才会继续运行
```python
//下面11行代码的含义就是在屏幕中输出一个 Hello World
#include<iostream>
using namespace std;
int main() {
cout << "hello C++" << endl; //屏幕显示hello C++
system("pause"); //按任意键继续退出程序
return 0;
}
```
运行结果
- hello C++
- 请按任意键继续. . .