1.统计重数及次数。2.hash。%p,若冲突,则向后移动。******************************#include#include#includeusing
namespace std;const int maxn=5000000;const int p=1200007;str...
分类:
其他好文 时间:
2014-06-09 22:34:07
阅读次数:
211
//convert string type value to double type
value string s = "23"; double d; istringstream
is(s); is>>d; cout<<d<<endl; //输出23 //convert double type
.....
分类:
编程语言 时间:
2014-06-09 22:15:55
阅读次数:
220
#include #include #include #include #include using
namespace std;ifstream& open_file(ifstream&,const string&);int
main(int argc, char **argv){ map ...
分类:
编程语言 时间:
2014-06-09 00:04:20
阅读次数:
334
昨天写的代码被殷老师诟病了,因为太「丑陋」。原来我的代码结构是这样的:public class
ColorRocognizer{ ..... public static void main(String args[]) { class ColorX {
p...
分类:
编程语言 时间:
2014-06-08 23:39:43
阅读次数:
296
///////////////////////////////////////////////////////////////////////////////////////////////////#import
"NSArray+swizzle.h"@implementation NSArray ...
分类:
移动开发 时间:
2014-06-08 22:41:02
阅读次数:
372
BufferedReader逐行读取import java.io.*;class Test{
public static void main(String args []){ FileReader reader =null; BufferedReader
buffe...
分类:
编程语言 时间:
2014-06-08 22:12:07
阅读次数:
434
第一种: static void Main() { object intList =
MakeList(typeof(int), 1, 2, 3); object strList = MakeList(typeof(string),
"sdfd", "fet"); //List foreach(o....
分类:
其他好文 时间:
2014-06-08 21:25:32
阅读次数:
336
#include #include #include #include using
namespace std;int cmp(const void *a,const void *b){ return *(int *)a-*(int
*)b;}int main(){ int n; ...
分类:
其他好文 时间:
2014-06-08 20:51:16
阅读次数:
202
Swift是一门类型安全语言,类型安全语言需要代码里值的类型非常明确。如果你的代码中有部分值需要String类型,你就不能错误地传递Int。鉴于Swift的类型安全,编译代码时,Swift会执行类型检查并将任何类型不匹配的地方标记为错误,使你在开发当中尽可能早的捕获并修正错误。类型检查有助于你在操作...
分类:
其他好文 时间:
2014-06-08 20:48:43
阅读次数:
245
数组必须开大点#include #include #include #include using
namespace std;struct node{ int x,ans;}q[1000005];int jx[]={-1,1};int n,k;int
map[1000005],v[100000...
分类:
其他好文 时间:
2014-06-08 20:48:03
阅读次数:
319