随笔分类 -  STL用法合集

摘要:vector.clear()不会释放内存,只是把size置零 和你链式存图 head=0 一样的,然后后面覆盖上 阅读全文
posted @ 2020-09-19 11:55 摸鱼选手LLF 阅读(133) 评论(0) 推荐(0)
摘要:优先队列默认由大到小,由小到大可以为 priority_queue<int,vector<int>,greater<int> > q; typedef struct node { int pi; int di; bool operator < (const node &b)const { if(pi 阅读全文
posted @ 2020-09-12 20:29 摸鱼选手LLF 阅读(169) 评论(0) 推荐(0)
摘要:训练了一波读脑残题 训练了一波后台数据出错还没得骂的心态,or蜜汁 题意? 复习了一波STL用法,练了一波手速, 题解:码农大模拟,end。。 #include<bits/stdc++.h> #define fi first #define se second #define io std::ios 阅读全文
posted @ 2020-09-11 21:01 摸鱼选手LLF 阅读(185) 评论(0) 推荐(0)