File tree Expand file tree Collapse file tree 1 file changed +15
-7
lines changed Expand file tree Collapse file tree 1 file changed +15
-7
lines changed Original file line number Diff line number Diff line change 11[ toc]
2- #### 注意边界
2+ ## 关于算法
3+ ### 二进制有点难
4+ ### 滑动窗口
5+ ### 动态规划
6+ ### 二分查找
7+ ### 回溯法
8+
9+
10+ ## C++相关
11+ ### 注意边界
312太多次越界了,很多时候CLion并不会报错~~ 难道是我漏看了exit code?~~
413一提交运行直接崩了
514
6- ### C++相关
7- #### 初始化列表的使用要小心
15+ ### 初始化列表的使用要小心
816``` c++
917vector<int > ret (n + 1, 1); // 初始化为n+1个1
1018vector<int > ret{n + 1, 1}; // 初始化为n + 1, 1两个元素!
1119```
1220
13- #### 普通数组也可以使用range for进行遍历
21+ ### 普通数组也可以使用range for进行遍历
1422
15- #### push_back vs emplace_back
23+ ### push_back vs emplace_back
1624[C++ difference between emplace_back and push_back function
1725](http://candcplusplus.com/c-difference-between-emplace_back-and-push_back-function)
18261. 如果对象的构造函数参数不止一个,push_back只能接受对象实例;emplace_back可以接受构造函数的参数!
@@ -31,7 +39,7 @@ push_back只能接受对象实例或者单参数版本的构造函数的参数
3139不会创建临时对象,而是直接在vector中创建对象。避免了创建不必要的临时对象
3240
3341
34- ### JetBrians产品中关于GitHub的fork、pull request使用
42+ ## JetBrians产品中关于GitHub的fork、pull request使用
3543[官方文档](https://www.jetbrains.com/help/idea/contribute-to-projects.html)
3644需要先**VCS | Git | Rebase my GitHub fork**
37- 之后就可以看到upstream
45+ 之后就可以看到upstream。日志、pull、Create Pull Request、View Pull Request都可以看得到upstream
You can’t perform that action at this time.
0 commit comments