码迷,mamicode.com
首页 >  
搜索关键字:i think i need a hou    ( 4897个结果
Leetcode-Sqrt(x)
Implement int sqrt(int x).Compute and return the square root of x.Analysis:Using binary search to find the solution. However, what need to be consider...
分类:其他好文   时间:2014-11-17 01:40:04    阅读次数:205
HDU 3037 Saving Beans(Lucas定理模板题)
Problem DescriptionAlthough winter is far away, squirrels have to work day and night to save beans. They need plenty of food to get through those long...
分类:其他好文   时间:2014-11-16 17:09:54    阅读次数:139
java筛选法求素数
这本身没什么,代码一堆发来纪念下而已本来刚学习java,编写输出100以内的素数对于我这个有代码运行性能洁癖的人(但是本身又不懂算法)来说,不能忍于是看了些资料参考:http://blog.csdn.net/program_think/article/details/7032600自己山寨一个(注意...
分类:编程语言   时间:2014-11-16 12:04:55    阅读次数:197
KISS My YAGNI
http://www.aqee.net/kiss-my-yagni/我们都知道KISS (Keep It Simple, Stupid)和 YAGNI (You Ain’t Gonna Need It)软件开发原则,然而,过度复杂的软件仍然随处可见。假设我们需要一个应用服务。没错,缺少分布式事务管理...
分类:其他好文   时间:2014-11-16 08:15:51    阅读次数:267
why is agreement hard in a distributed system?
same question as:why is PAXOS necessary?1, what if >1 nodes become leaders simultaneously?that's why we need phase#1 (prepare) to select a leader.2, w...
分类:其他好文   时间:2014-11-16 08:15:30    阅读次数:210
银行家算法
1 #include 2 #include 3 #include 4 using namespace std; 5 int work,progress,available[100],mmax[100][100],allocation[100][100],need[100][100]; ...
分类:编程语言   时间:2014-11-15 17:02:36    阅读次数:321
POJ-1005 I Think I Need a Houseboat
【问题描述】 Fred想在一块地上买房子,但那块地每年都会收缩50m2,给定一个房子坐标,输出几年后房子会被侵蚀入海中。 【思路分析】 该题也算是简单题,只要读懂题目就没什么问题了。 唯一要注意的地方是每年会收缩50m2,如果在上一年的基础上算收缩50m2会呈一个半环形,比较麻烦。索性直接计算出从开...
分类:其他好文   时间:2014-11-15 16:53:03    阅读次数:224
一道难题
描述Today, I want to take a few minutes to speak with you-directly and clearly-about Ebola: what we're doing about it, and what you need to know. Becaus...
分类:其他好文   时间:2014-11-14 22:26:11    阅读次数:221
POJ 3468 A Simple Problem with Integers(线段树区间求和)
Description You have N integers, A1, A2, ... , AN. You need to deal with two kinds of operations. One type of operation is to add some given number to each number in a given interval. The other is ...
分类:其他好文   时间:2014-11-14 01:41:58    阅读次数:245
AFN检测网络情况
问: I'm a bit lost on AFNetorking's Reachability and haven't found a lot of good information out there. I have an app that logs into a web API. Each VC connects to the API in some way so each VC need...
分类:其他好文   时间:2014-11-14 00:19:13    阅读次数:393
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!