- 博客(10)
- 收藏
- 关注
原创 windows 线程同步
最近面试被问到Windows下的线程同步,有的地方记不清了,只好把老视频找出来,对照整理一下。 一、原子操作 1、InterlockedIncrement: 加1操作; 2、InterlockedDecrement: 减1操作; 3、InterlockedExchangeAdd: 加上指定的值,也可以加上一个负数; 4、InterlockedExchange、InterlockedExchangePointe: 能够以原子操作的方式用第二个参数的值取代第一个参数的值; 二、临界区域 Critic
2020-05-11 22:31:46
397
原创 VS2019 无法识别类名
在WIN10上新建了一个TXT,然后改后缀导入到VS2019的项目中。然后问题出现了:头文件明明声明了,就是识别不了类名; 解决方法:把原来的改后缀的文件删了,在VS2019中新建文件。 ...
2020-03-28 11:32:40
2440
原创 图片和文本在剪贴板中的存储
CF_UNICODETEXT、CF_OEMTEXT、CF_TEXT、CF_DIB,、CF_DIBV5在剪贴板中是一块内存 CF_BITMAP是一个句柄
2019-06-26 17:37:53
873
原创 c++ 双链表、双向循环的创建、删除、添加
/* 双链表 */ typedef struct _DoubleLinkList{ int val; struct _DoubleLinkList *pre; struct _DoubleLinkList *next; }DoubleLinkList; // 头插法初始换双链表 DoubleLinkList* Creat_DoubleLinkList_Head() { DoubleLi...
2019-05-12 21:20:16
1393
原创 c++ 单循环链表的创建、添加、删除
// 单向循环链表 typedef struct _CircleLinkList{ int val; struct _CircleLinkList* next; }CircleLinkList; // 初始单向循环链表化链表——头插法 CircleLinkList* Create_LinkList_Head() { CircleLinkList* head, * node; int x...
2019-05-08 17:47:49
3615
原创 单链表的初始化、删除、添加 c++
根据下面博客学习的: https://blog.youkuaiyun.com/Poxiao2017/article/details/80445145 https://blog.youkuaiyun.com/qq_41028985/article/details/82859199 #include "stdafx.h" #include "iostream" using namespace std; /* 单链...
2019-05-07 22:02:14
2616
原创 去除首尾空格
第一种: wstring strTest; strTest= strTest.erase(strTest.find_last_not_of(L" ") + 1); strTest= strTest.erase(0, strTest.find_first_not_of(L" ")); 第二种: cstring strTest; strTest= ((CString)strTe...
2019-02-28 10:42:30
1096
原创 python psutil 获取进程的句柄数
写脚本的时候,需要获取进程的句柄数,找了好久,记录一下。 使用psutil中的num_handles()。
2018-12-03 21:07:49
3515
原创 超市管理系统
fruit类package 练习; public class fruits { private String fruitName; private int price; private int num; private String info; public fruits(String fruitName, int price, int num, String info) {...
2018-06-20 00:11:11
2394
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人
RSS订阅
3