2022年11月18日

摘要: //对reference & 和 dereference * 的进一步理解//#include"iostream" int main() { int a = 9; //等号左边&为引用,取alias 举个例子// int& a = b; b = 10; std::cout<<a<<","<<b<<s 阅读全文
posted @ 2022-11-18 17:55 yangpeiqi 阅读(17) 评论(0) 推荐(0) 编辑

2022年11月13日

摘要: //For class using ,you can set a serious of macro to predict something////when you call this macro ,the template could make a new function by your inp 阅读全文
posted @ 2022-11-13 13:39 yangpeiqi 阅读(6) 评论(0) 推荐(0) 编辑

2022年11月12日

摘要: #include<iostream>#include<stdio.h>#include<vector>#include<string>//Find a element in container function////You can use the function to find a elemen 阅读全文
posted @ 2022-11-12 18:30 yangpeiqi 阅读(15) 评论(0) 推荐(0) 编辑
摘要: int main(){ int* const array; const int* array; int a = 10; array = &a;//You can't exchange array self , array just is a integar// *array = 13;//This 阅读全文
posted @ 2022-11-12 14:21 yangpeiqi 阅读(11) 评论(0) 推荐(0) 编辑