![](https://img-blog.csdnimg.cn/20201014180756922.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
算法
did_you
不积小流,无以成江海
展开
-
以区间为单位的二分查找
【2019回家过年前的一记】问题场景:区间的格式如下,整体为一个Json字符串,每个区间的startTime和endTime都是按照从小到大的顺序排列的。"[{\"endTime\":1578633955,\"startTime\":1578626876},{\"endTime\":1578640268,\"startTime\":1578634050},{\"endTime\":15...原创 2020-01-20 18:51:23 · 334 阅读 · 0 评论 -
最小顶点覆盖的混合贪心算法
NP问题:基于无向图的最小顶点覆盖的混合贪心算法(MGA)#include#include#include#include#include#include#include#define MAX 100using namespace std;int n,m;struct Edge{ int u,v;};struct Point{ int id;原创 2018-01-11 20:10:27 · 4751 阅读 · 3 评论 -
n皇后问题(带界面)
好久没有逛csdn了,今天来看看,顺便把最近写的一个东西上传,挣扎了很久,终于决定2019考研了,复习资料已经到手,从今天开始,一定沉下心来好好做题。有好多想做的事没做(不敢做),可是大学生活已过大半,虽有遗憾,有后悔,可是。。。。。岁月像一场有去无回的旅行,好的坏的都是风景不是么??(我喜欢的那个女孩,再见)原创 2017-10-17 18:02:14 · 928 阅读 · 1 评论 -
电路布线问题
#include #include using namespace std;#define M 10#define N 10typedef struct{ int row,col;}Position;int grid[M+2][N+2];int Pathlen;Position * path;bool fin原创 2017-10-17 17:55:07 · 418 阅读 · 0 评论