摘要: 在官方文档中,有这么一段 其文件中默认的地址为: 由于我是一个先用后看的人,所以我的项目文件有着我之前下过的插件,并且新建的插件文件夹也直接建在了langbot/plugin文件夹中,导致我反复修改都无法启动调试成功,不是拒绝连接就是http 400,甚至以为这个地址要改成NapCat中的webso 阅读全文
posted @ 2025-12-16 21:23 秋秋秋秋秋寒 阅读(2) 评论(0) 推荐(0)
摘要: #include <string> #include <iostream> #include <algorithm> #include <initializer_list> using namespace std; template<class T> class myArray { // 类模板 友 阅读全文
posted @ 2025-10-23 21:47 秋秋秋秋秋寒 阅读(5) 评论(0) 推荐(0)
摘要: 今天学了一下C++的ofstream写文件,代码肯定没问题,环境是win10虚拟机,软件是vs2019 ofstream ofs; ofs.open("test.txt", ios::out); ofs << "姓名:张三" << endl; ofs << "性别:男" << endl; ofs < 阅读全文
posted @ 2025-10-19 20:38 秋秋秋秋秋寒 阅读(4) 评论(0) 推荐(0)
摘要: class Animal { public: void speak() { cout << "Animal.speak()" << endl; } }; class Cat :public Animal { void speak() { cout << "Cat.speak()" << endl; 阅读全文
posted @ 2025-10-18 23:10 秋秋秋秋秋寒 阅读(9) 评论(0) 推荐(0)
摘要: 1、加号运算符重载(加减乘除) 首先假设你有一个Person类,里面有个成员变量m_a和m_b,现在你想使p1+p2等价于p1.m_a+p2.m_a,p1.m_b+p2.m_b class Person { public: Person() {}; Person(int a, int b) : m_ 阅读全文
posted @ 2025-10-18 21:00 秋秋秋秋秋寒 阅读(31) 评论(0) 推荐(0)
摘要: const int *p:其地址可变,内容不可变。个人记法为去掉int为const *p,const修饰*p,而*p又指其内容,所以内容不可变。 int * const p:其内容可变,地址不可变。个人记法为去掉int为*const p,const修饰p,p不可变则其地址不可变。 因为这两叫什么常量 阅读全文
posted @ 2025-10-15 21:03 秋秋秋秋秋寒 阅读(4) 评论(0) 推荐(0)
摘要: 1、以值返回局部对象 class Person { public: Person(int age) { this->age = age; } // 以值方式返回局部对象会调用拷贝构造生成一个新的对象返回 Person PersonAddPerson(Person p) { this->age += 阅读全文
posted @ 2025-10-15 20:37 秋秋秋秋秋寒 阅读(3) 评论(0) 推荐(0)