We have spent last couple of months stabilizing thelock detection functionality in Plumbr. During this we have stumbled into many tricky concurrency i...
分类:
其他好文 时间:
2014-08-14 16:34:38
阅读次数:
227
HDFS ArchitectureIntroductionThe Hadoop Distributed File System (HDFS) is a distributed file system designed to run on commodity hardware. It has many...
分类:
其他好文 时间:
2014-08-14 16:23:38
阅读次数:
275
题意 中文 但要注意小于你能量的点也是能到达的
令d[i][j]表示到达第i行第j列的方法数 初始化为0 d[1][1]为1 输入一个点的能量t后 枚举这个点能到的所有点(i+x,j+y)(x+y<=t) 有d[i+x][j+y]+=d[i][j] 因为只能向右走和向下走 可以保证每次更新后均为当前最优解 输入最后一个点后 就得到答案了...
分类:
其他好文 时间:
2014-08-14 10:52:08
阅读次数:
195
题目地址:HDU 1086
就这么一道仅仅判断线段相交的题目写了2k多B的代码。。是不是有点浪费。。。但是我觉得似乎哪里也优化不了了。。。。
判断线段相交就是利用的叉积。假如现在两条线段分别是L1和L2,先求L1和L2两个端点与L1的某个端点的向量的叉积,如果这两个的叉积的乘积小于0的话,说明L1在是在L2两个端点之间的,但此时并不保证一定相交。此时需要用同样的方法去判断L2是否在L1的两个端...
分类:
其他好文 时间:
2014-08-13 22:30:37
阅读次数:
307
老师介绍:Stephen Boyd, 这是他的书网站Convex Optimization http://web.stanford.edu/~boyd/cvxbook/,有pdf和课程。
Kown the big picture 模块化,了解概念,会应用到实际问题,就挺好,很多数学很难的。
Many...
分类:
其他好文 时间:
2014-08-13 22:21:57
阅读次数:
268
今天实施同事报现场有一个节点无法访问,把现场的weblogic日志拿回来,显示如下:
<Unable to create a server socket for...
分类:
编程语言 时间:
2014-08-13 18:45:57
阅读次数:
259
题目链接题意 : 给你N,然后再给M个数,让你找小于N的并且能够整除M里的任意一个数的数有多少,0不算。思路 :用了容斥原理 :ans = sum{ 整除一个的数 } - sum{ 整除两个的数 } + sum{ 整除三个的数 }………………所以是奇加偶减,而整除 k 个数的数可以表示成 lcm(A...
分类:
其他好文 时间:
2014-08-13 00:34:54
阅读次数:
336
Insertion Sort is a simple sorting technique which was covered in previous challenges. Sometimes, arrays may be too large for us to wait around for in...
分类:
其他好文 时间:
2014-08-12 18:13:14
阅读次数:
404
Follow up for "Unique Paths":Now consider if some obstacles are added to the grids. How many unique paths would there be?An obstacle and empty space i...
分类:
其他好文 时间:
2014-08-12 16:40:14
阅读次数:
157
Solution:Apparently, I am too naive and I think too few. Here's the detailed solution.What is our chat server?This is something you should discuss wit...
分类:
其他好文 时间:
2014-08-12 05:53:23
阅读次数:
210