代码改变世界

阅读排行榜

杭电oj 1541 树状数组

2011-09-28 11:25 by javaspring, 184 阅读, 收藏,
摘要: 暑假时和xd讨论过这道题,当时迷迷糊糊的做了出来,昨天做专题练习时,怎么也想不出来怎么和树状数组联系起来。昨天想了有几个小时,今天又想了想,终于想了出来。自己感觉这是一道树状数组的好题,也是有一定难度的。题目:Astronomers often examine star maps where stars are represented by points on a plane and each star has Cartesian coordinates. Let the level of a star be an amount of the stars that are not hi... 阅读全文

UESTCOJ 1655 Journey

2012-05-07 10:34 by javaspring, 182 阅读, 收藏,
摘要: 我擦,这道题的代码写的那是一个纠结,写出来之后自己看着也是非常的搓。。这是道水题啊,还纠结了这么久,,太弱了。。。。。。 思路:由于只有1000个点,所以可以枚举,复杂度为(n*n),是可以过的。对于每个点,枚举去掉每条边后的值,取最小的即可。ac代码:#include <iostream> #include <cstdio> #include <string.h> #include <cmath> using namespace std; #define min(x,y) x<y ? x:y #define max(x,y) x>y 阅读全文

杭电 2852 树状数组+二分

2012-02-17 13:59 by javaspring, 182 阅读, 收藏,
摘要: 题目:KiKi's K-NumberTime Limit: 4000/2000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 1314Accepted Submission(s): 565Problem DescriptionFor the k-th number, we all should be very familiar with it. Of course,to kiki it is also simple. Now Kiki meets a very similar 阅读全文

2012年8月25日---学习笔记---概率

2012-08-25 00:37 by javaspring, 181 阅读, 收藏,
摘要: 面试题: Please write out the program.#include <stdlib.h> #include <stdio.h> #define LOOP 1000 void main() { int ragnc=0; for(int i=0;i!=LOOP;i++) { int x=rand(); int y=rand(); if(x*x+y*y<RAND_MAX*RAND_MAX) ragnc++; } printf("%d",ragnc); }测试的结果值: ....解析一下: 设上面园的半径为R,对应到Program中其 阅读全文

Android开发视频教学_mars老师的视频(第三季)

2012-08-18 15:40 by javaspring, 181 阅读, 收藏,
摘要: 下载地址:http://www.jiyanet.com/read.php?tid=391 阅读全文
上一页 1 ··· 96 97 98 99 100 101 102 103 104 ··· 126 下一页