C++
文章平均质量分 77
lrsage
这个作者很懒,什么都没留下…
展开
-
动态链接库DLL创建和简单使用
工具:Visual Studio 2017 通过__declspec(dllexport)关键字指定需要导出的目标,然后在使用dll的程序中通过__declspec(dllimport)关键字指定导入的目标,实现在外部(别的程序)访问定义在dll中的变量、函数和类。详细过程如下,其中1-x是创建一个简单的DLL项目,2-x是对刚创建的Dll1项目的简单使用:1-1. 创建一...原创 2018-11-21 16:38:54 · 429 阅读 · 0 评论 -
实现对带边框QWidget不能最大化、不能最小化、不能通过鼠标拖动边框改变该控件的大小、使用鼠标拖动标题栏不能改变该控件的位置
1、设置带边框的QWidget不能最大化,最小化,以及固定大小(不能通过鼠标拖动边框改变该控件的大小):可以通过setWindowFlags();函数对窗口样式进行设置t::WindowFlags flags = 0;flags |= Qt::Window; // 设置控件显示为为窗口样式flags |= Qt::WindowCloseButt...原创 2018-12-27 15:06:07 · 1535 阅读 · 0 评论 -
LeetCode: 338. Counting Bits
题目描述:338. Counting BitsMediumGiven a non negative integer numbernum. For every numbersiin the range0 ≤ i ≤ numcalculate the number of 1's in their binary representation and return them as ...原创 2019-07-18 22:57:53 · 130 阅读 · 0 评论 -
LeetCode: 136. Single Number
题目描述:136.Single NumberEasyGiven anon-emptyarray of integers, every element appearstwiceexcept for one. Find that single one.Note:Your algorithm should have a linear runtime complexity. C...原创 2019-07-19 21:59:47 · 170 阅读 · 0 评论 -
LeetCode:406. Queue Reconstruction by Height
题目描述:406.Queue Reconstruction by HeightMediumSuppose you have a random list of people standing in a queue. Each person is described by a pair of integers(h, k), wherehis the height of the pe...原创 2019-07-28 12:34:13 · 248 阅读 · 0 评论