Skip to content
This repository was archived by the owner on Jan 27, 2021. It is now read-only.

Commit 0c6ba27

Browse files
author
Chen Xiaowei
committed
1. update 7-1
1 parent 622ffa7 commit 0c6ba27

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

content/chapter7/chapter7-1-chinese.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@
2020
#include <algorithm>
2121

2222
using namespace std;
23+
using namespace std::literals;
2324
```
2425
2526
2. 首先来创建字符串对象,这里`a`就为一个`string`对象。我们使用C风格的字符串对其进行构造(编译后,C风格的字符串就成为静态数组)。构造函数将对其进行拷贝,然后构成一个字符串对象。或者也可直接使用字符字面值操作符`""s`来代替C风格的字符串。其也会在运行时创建一个字符串对象,这里`b`也是一个字符串对象,不过这里我们让程序自己去推断这个类型:

0 commit comments

Comments
 (0)