自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

WHJObject的博客

脚踩西瓜皮,滑到哪学到哪

  • 博客(10)
  • 资源 (3)
  • 收藏
  • 关注

原创 cmake记坑帖

使用Dlib,然后用 python setup.py build ,结果蹦出来个errormissing PYTHON_LIBRARIES and PYTHON_INCLUDE_DIRS,解决办法是安装 python-devel,醉了环境为 openSUSE Leap 42.1

2016-04-02 01:16:38 447

原创 算法导论22.3-13

题目:判断一个图是否为单联通图对图做DFS,对每个点记录 in 和 out ,in为遍历到的时间点,out为离开该点极其所有后续的时间点如果一个点出现了第二次 in,也就是第二次被遍历到(在这种情况下应当停止向下遍历,但依然加上一个in[2]),如果in[2]>out[1],则必然是有第二条简单路径到达该点。

2016-02-22 21:19:22 2188

原创 算法导论22.2-8

题目:Thediameter of a tree T D .V; E/ is defined as , that is, thelargest of all shortest-path distances in the tree. Give an efficient algorithm tocompute the diameter of a tree, and an

2016-02-19 16:17:58 733

原创 j2ee学习 记坑贴

坑1标签中的话,其值无法上传。用hibernate更新,id设置为disabled,结果更新报错如下Batch update returned unexpected row count from update [0]; actual row count: 0; expected: 1; nested找了半天才发现是id值没有传进去...

2016-02-15 16:48:28 353

原创 算法导论15-6公司聚会计划Planning a company party

Professor Stewart is consulting for the president of a corporation that is planninga company party. The company has a hierarchical structure; that is, the supervisorrelation forms a tree rooted at

2016-02-10 21:33:22 3652

原创 算法导论第三版15-4整齐打印Printing neatly

Consider the problem of neatly printing a paragraph with a monospaced font (all characters having the same width) on a printer. The input text is a sequence of n words of lengthsl1; l2; ···; ln,

2016-02-09 22:56:42 3314

原创 算法导论15

原题:设计一个O(n^2)时间的算法,求一个n个数的序列的最长单调递增子序列想法:记录每个位置元素一定被包含在其中的子序列的最大长度靠后的元素加入的子序列依赖之前的子序列两个for循环,O(n^2)显然#includeusing namespace std;struct lAndMax{ int length, max;};int main(){ in

2016-02-08 20:16:20 390

转载 算法导论14.1-8

原题现在有一个圆上的n条弦,没条弦都由其端点定义。请给出一个能在O(n*log(n))时间内确定圆内相交弦的算法。此题想了蛮久,知道两条弦的端点如果顺序交叉分布,那么就能推出相交但是圆上点的排序,或者说怎么拿弦建树不知道,难以下手思想来源于以下链接http://bbs.youkuaiyun.com/topics/280085502有人把文字以更加容易理解的方式表述了一下(是否更

2016-02-06 16:23:46 644

原创 算法导论第三版快速排序(三数取中划分)Median-of-3 partition

7-5中文版 page 105英文版 page 188a.对x=A'[i]必然有1,...,i-1, i, i+1,...,np[i] = (i-1)*(n-i)/(C(n,3))所以i=1和n时pi=0b.平凡实现:1/n三数取中:p[(n+1)/2]直接做差吧,我没有划成比较具有美感的式子不过两个值都是趋于0,差也是0,n->infinity

2016-01-24 16:35:09 2743

原创 directx 11.0 学习之 chapter 4 源码

introduction to 3d game programming with directx 11.0 chapter 4

2015-12-29 15:48:08 967

World of Warcraft Programming 2nd Edition pdf

开发World of warcraft的书

2015-05-09

算法导论_英文版_第三版.pdf

算法导论第三版英文版电子版,非扫描,有书签,配合自己的算法导论博客学习

2016-01-24

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除