07 2022 档案
摘要:1、使用自定义函数: #include <iostream> using std::cout; using std::endl; using std::string; string toBinary(int n) { string r; while (n != 0){ r += ( n % 2 ==
阅读全文
摘要:vector<vector<int>> test0 = { {3, 7}, {2, 4}, {10, 30} }; sort(test0.begin(), test0.end(), [](vector<int> a, vector<int> b){return a[0] < b[0];});
阅读全文
摘要:https://www.cnblogs.com/hokyhu/archive/2009/03/30/1425604.html
阅读全文
摘要:c++中system("pause") 简单来说就是暂停的意思,一般在LINUX编程时会用到,等待接收信号,才会重新运行 。 在进行C/C++编程的时候,在运行程序查看输出效果时,会出现窗口闪一下就关闭的情况。 在C语言中一般通过添加getchar(); 在C++中一般在main函数中的return
阅读全文