题意: 有兩個人在玩遊戲,有N個數,FF會詢問TT,sum(a, b)=A[a] + ... +A[b]是多少,TT會告訴他正確的答案,也會告訴他錯誤的。要你統計錯誤的答案有多少組。(如果當前的是錯的統計完就直接忽略掉)总结:这道题花了我很长时间,结果还是看了别人的题解才想到的。其实就是一个小细节....
分类:
其他好文 时间:
2014-08-16 13:47:40
阅读次数:
185
1:1:MySql Host is blocked because of many connection errors; unblock with 'mysqladmin flush-hosts' 解决方法环境:linux,mysql5.5.21错误:Host is blocked because ...
分类:
其他好文 时间:
2014-08-16 09:43:30
阅读次数:
2019
Unique Binary Search TreesGivenn, how many structurally uniqueBST's(binary search trees) that store values 1...n?For example,Givenn= 3, there are a to...
分类:
其他好文 时间:
2014-08-16 00:59:29
阅读次数:
178
Description
Sewing Buttons with Grandma
After so many years of studying math in the Academy of Colombian Mathematics (ACM) in the tropic, Eloi has finally decided to visit hi...
Sorting is often useful as the first step in many different tasks. The most common task is to make finding things easier, but there are other uses als...
分类:
其他好文 时间:
2014-08-15 12:45:48
阅读次数:
382
~~~~
果然用map暴力直接超时。原来要用hash,第一次写hash,真是个好玩的东西。
题目链接:http://poj.org/problem?id=1200
注意:1.题目说文本是由字符组成的,所以要用ascll码作为下标。
2.hash数组要开大点,否则RE。
#include
#include
#include
#include
#include
#define N 1...
分类:
其他好文 时间:
2014-08-15 08:17:47
阅读次数:
233
Ubiquitous Religions
Time Limit: 1000MS Memory limit: 65536K
题目描述
There are so many different religions in the world today that it is difficult to keep track of them all. You are in...
分类:
其他好文 时间:
2014-08-15 08:17:17
阅读次数:
229
How Many Fibs?Time Limit: 2000/1000 MS (Java/Others)Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 4235Accepted Submission(s): 1669Prob...
分类:
其他好文 时间:
2014-08-15 01:20:06
阅读次数:
297
Description
Many people like to solve hard puzzles some of which may lead them to madness. One such puzzle could be finding a hidden prime number in a given text. Such number could be the number of d...
分类:
其他好文 时间:
2014-08-14 23:55:56
阅读次数:
329
在使用ab做压力测试的时候发现当并发设置为1000以上的时候就出现[root@DB~]#ab-n10000-c1500http://192.168.100.208/
ThisisApacheBench,Version2.3<$Revision:655654$>
Copyright1996AdamTwiss,ZeusTechnologyLtd,http://www.zeustech.net/
LicensedtoTheApacheSoftware..
分类:
其他好文 时间:
2014-08-14 20:58:29
阅读次数:
227