码迷,mamicode.com
首页 >  
搜索关键字:floating point    ( 7266个结果
LeetCode:Container With Most Water
题目链接 Given n non-negative integers a1, a2, ..., an, where each represents a point at coordinate (i, ai). n vertical lines are drawn such that the two ...
分类:其他好文   时间:2014-07-07 22:25:30    阅读次数:359
Problem Copy List with Random Pointer
Problem Description:A linked list is given such that each node contains an additional random pointer which could point to any node in the list or null...
分类:其他好文   时间:2014-07-07 16:19:01    阅读次数:188
Unity3D中UI图片模糊,不清晰解决怎么解决
很久没写博文,今天刚好有同事问到:NGUI为什么做的界面图片那么模糊,比美术给的图片相比不是很清晰。 其实这个问题解决方法很简单,只要把NGUI生成的图集的图片类型改成“GUI”或者“Advance”(去掉generate mip maps),而且Filter Mode都选择(Point)。 这样即可。...
分类:其他好文   时间:2014-07-01 09:00:07    阅读次数:321
被攻击减血,攻击可增加等级
/* *  备忘录模式 */ #include   //保存值 class mySavevalue  { public:  mySavevalue(string user_name = "",           int life_value = 100,        int magic_point = 100,        int rank_values =...
分类:其他好文   时间:2014-07-01 08:49:27    阅读次数:203
创建android画笔程序的例子(有镜面效果)
关键是在检测到手指移动的时候用mPath.quadTo的方法,android sdk解释是: Add a quadratic bezier from the last point, approaching control point (x1,y1), and ending at (x2,y2). If no moveTo() call has been made fo...
分类:移动开发   时间:2014-07-01 08:07:39    阅读次数:289
UVA 784 Maze Exploration
题目如下: Maze Exploration  A maze of rectangular rooms is represented on a twodimensional grid as illustrated in figure 1a. Each point of thegrid is represented by a character. ...
分类:其他好文   时间:2014-07-01 06:57:08    阅读次数:231
Copy List with Random Pointer
题目 A linked list is given such that each node contains an additional random pointer which could point to any node in the list or null. Return a deep copy of the list. 方法 publi...
分类:其他好文   时间:2014-06-30 19:36:33    阅读次数:163
Max Points on a Line
题目 Given n points on a 2D plane, find the maximum number of points that lie on the same straight line. 方法 每次选择一个点,和其他n - 1个点,进行判断,统计最多的。 double computeSlope(Point a, Point b) { ...
分类:其他好文   时间:2014-06-30 15:48:45    阅读次数:184
hdu 3264 Open-air shopping malls 求两圆相交
对每个圆二分半径寻找可行的最小半径,然后取最小的一个半径。 对于两圆相交就只要求到两个扇形,然后减去两个全等三角形就行了。 #include #include #include #include using namespace std; #define pi acos(-1.0) #define eps 1e-8 #define maxn 50 int n; struct point{...
分类:其他好文   时间:2014-06-29 22:36:16    阅读次数:247
LeetCode: Copy List with Random Pointer [138]
【题目】 A linked list is given such that each node contains an additional random pointer which could point to any node in the list or null. Return a deep copy of the list. 【题意】 给定一个链表,每个节点除了next指针外,还有一个random指针,指向任意的节点。 要求,复制这样的一个链表 【思路】 思路...
分类:其他好文   时间:2014-06-29 20:41:21    阅读次数:232
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!