- 博客(4)
- 收藏
- 关注
原创 【C++ Function】Talk about reference ‘&‘
The reference can only be set by initialization, and its value cannot be set or changed by assignment. Simply put, it must be initialized at the statement of reference. This is a very big difference between references and pointers. //correct, initial.
2021-06-24 19:46:09 154 3
原创 【C++ Function】Three ways to pass parameters
If we wants to make a parameter-passing, there are usually thee ways to go, namely common parameters, pointer parameters and quoting parameters. Common parameters The parameters passed into the function in this form is formal parameters, which means is do
2021-06-17 11:28:40 72
原创 【C++ STL】pointer access of vector
When our vector is declared in the form of a pointer, we need to access its elements through an iterator, which cannot simply be similar to C language, using pointers and arrays.The sample code is as follows. #include <bits/stdc++.h> using namespace
2021-06-16 19:18:45 131
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人