上一页 1 ··· 3 4 5 6 7
摘要: # 第一种方法 必须使用5来限制参数类型是int[5],另一个参数可以指定 ```c++ void print(int m[][5],int dim1){ for(int i = 0; i!= dim1; i++){ for(int j = 0; j != 5; j++){ std::cout << 阅读全文
posted @ 2023-03-07 12:41 摩天仑 阅读(109) 评论(0) 推荐(0) 编辑
摘要: ```c++ // 3种形式 void comp(int arg[10]){}; // 对数组元素的个数进行限制,超过10的数组只会截取前10个 void comp(int arg[]){}; void comp(int* arg){}; ``` 阅读全文
posted @ 2023-03-07 12:39 摩天仑 阅读(30) 评论(0) 推荐(0) 编辑
摘要: std::string to_string(int); // 例子 string str = to_string(x); 阅读全文
posted @ 2023-03-07 12:38 摩天仑 阅读(58) 评论(0) 推荐(0) 编辑
摘要: // string<——>wstring #include <codecvt> std::string wstring2utf8string(const std::wstring& str) { static std::wstring_convert<std::codecvt_utf8<wchar_ 阅读全文
posted @ 2023-03-07 12:38 摩天仑 阅读(53) 评论(0) 推荐(0) 编辑
摘要: 用到的技术 1、 使用easyx图形库进行绘制; 2、 使用time.h时间种子产生随机数; 3、 使用conio.h响应键盘的操作; 一、爱心的结构体 struct Point { double x, y; // 坐标 COLORREF color; // 颜色 }; 二、初始化数据 COLORR 阅读全文
posted @ 2023-03-07 12:38 摩天仑 阅读(428) 评论(0) 推荐(0) 编辑
摘要: ## 代码提示(已在环境变量中声明) 即下方的Qt_INCLUDEPATH ![image-20221104170257699](http://test-123456-md-images.oss-cn-beijing.aliyuncs.com/img/image-20221104170257699. 阅读全文
posted @ 2023-03-07 12:28 摩天仑 阅读(22) 评论(0) 推荐(0) 编辑
摘要: ## 1、下载opencv [github](https://github.com/opencv/opencv/releases) 这里下载3.4版本的,下载4.0版本容易出错 ## 2、安装opencv D:\opencv\opencv-3.4.16\opencv ## 3、CMake构建 ### 阅读全文
posted @ 2023-03-07 12:22 摩天仑 阅读(247) 评论(0) 推荐(0) 编辑
摘要: # 解决QT creator预览和实际不相符 在main函数里添加 ```c++ // 增加下面的一个代码 if(QT_VERSION>=QT_VERSION_CHECK(5,6,0)) QCoreApplication::setAttribute(Qt::AA_EnableHighDpiScali 阅读全文
posted @ 2023-03-07 12:21 摩天仑 阅读(189) 评论(0) 推荐(0) 编辑
上一页 1 ··· 3 4 5 6 7