随笔分类 - c++
摘要:/* "/Users/macname/Desktop/aa-1.log" 链接:https://pan.baidu.com/s/1fKB5vXDe6bYOhoslc-kr7w 密码:nb9s */ code:
阅读全文
摘要:库:链接:https://pan.baidu.com/s/1UChrgqLPJxKopyqShDCHjg 密码:3yhz 输出
阅读全文
摘要:#字符串转整数 string ss="-99"; cout<< stoi(ss)<<endl;
阅读全文
摘要:输出 demo2 输出 参考:https://www.cnblogs.com/xiugeng/p/9687354.htmlhttps://blog.csdn.net/weixin_41106545/article/details/83211418
阅读全文
摘要:#include using namespace std; int main() { cout << "char: " << sizeof(char) << " 字节" << endl; cout << "int: " << sizeof(int) << " 字节" << endl; cout << "float: " << sizeof(float)...
阅读全文
摘要:#include using namespace std; int main() { char c; int isLowercaseVowel, isUppercaseVowel; cout > c; // 小写字母元音 isLowercaseVowel = (c == 'a' || c == 'e' || c == 'i' || c =...
阅读全文
摘要:#include using namespace std; int main() { char op; float num1, num2; cout > op; cout > num1 >> num2; switch(op) { case '+': cout << num1+num2; ...
阅读全文
摘要:#include #include using namespace std; int main() { // 创建一个向量存储 int vector vec; int i; // 显示 vec 的原始大小 cout ::iterator v = vec.begin(); while( v != vec.end()) { cout ...
阅读全文
摘要:/* //多继承 #include using namespace std; class Sofa { public: Sofa(); ~Sofa(); void sit() { coutweight = w; } int getWeight() { return this->weight;...
阅读全文
摘要:code: 输出
阅读全文
摘要:// reverse_copy example #include // cout #include // reverse_copy #include // vector using namespace std; int main () { int myints[] ={1,2,3,4,5,6,7,8,9}; vector myvector; my...
阅读全文
摘要:// reverse algorithm example #include // std::cout #include // std::reverse #include // std::vector using namespace std; int main () { vector myvector; // set some values: f...
阅读全文