自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(23)
  • 收藏
  • 关注

原创 HDU 2204 Eddy's爱好(数论)

题目:(中文题)问题是这样的:给你一个正整数N,确定在1到N之间有多少个可以表示成M^K(K>1)的数。本题有多组测试数据,每组包含一个整数N,1对于每组输入,请输出在在1到N之间形式如M^K的数的总数。每组输出占一行。Simple Input:10361000000000000000000Simple Output:49100100

2014-12-13 23:54:18 944

原创 HDU 4279 Number(数论)

题目:Here are two numbers A and B (0   For each x, f(x) equals to the amount of x’s special numbers.  For example, f(6)=1, because 6 only have one special number which is 4. And f(12)=3, its speci

2014-12-13 22:44:20 315

原创 HDU 2608 0 or 1(数论)

题目:define T(n) as the sum of all numbers which are positive integers can divied n. and S(n) = T(1) + T(2) + T(3)…..+T(n). Hint S(3) = T(1) + T(2) +T(3) = 1 + (1+2) + (1+3) = 8 S(3) % 2 = 0

2014-12-13 22:07:06 303

原创 HDU 1124 Factorial(数论)

题目:The most important part of a GSM network is so called Base Transceiver Station (BTS). These transceivers form the areas called cells (this term gave the name to the cellular phone) and every phon

2014-12-07 21:52:40 336

原创 HDU 2964 Prime Bases(数论)

题目:Given any integer base b >= 2, it is well known that every positive integer n can be uniquely represented in base b. That is, we can writen = a0 + a1*b + a2*b*b + a3*b*b*b + ... where the

2014-12-07 21:29:27 299

原创 HDU 2674 N!Again(数论)

题目:Each line will contain one integer N(0 For each case, output N! mod 2009Simple Input:4 5Simple Output:24120题目分析:乍一看,本题感觉要用数组,因为N的范围太广,但是结果模2009,这就立刻简化了此题的思路。(可以有好多重复项不去算)原来4

2014-12-01 19:28:05 295

原创 HDU 1198 Farm Irrigation(深搜)

题目:Benny has a spacious farm land to irrigate. The farm land is a rectangle, and is divided into a lot of samll squares. Water pipes are placed in these squares. Different square has a different typ

2014-11-30 23:05:35 254

原创 HDU 1518 Square(深搜)

题目:Given a set of sticks of various lengths, is it possible to join them end-to-end to form a square?The first line of input contains N, the number of test cases. Each test case begins with an i

2014-11-30 20:19:47 293

原创 HDU 1195 Open the Lock(广搜)

题目:Now an emergent task for you is to open a password lock. The password is consisted of four digits. Each digit is numbered from 1 to 9. Each time, you can add or minus 1 to any digit. When add 1

2014-11-30 19:23:30 274

原创 HDU 1016 Prime Ring Problem(深搜)

题目概述:A ring is compose of n circles as shown in diagram. Put natural number 1, 2, ..., n into each circle separately, and the sum of numbers in two adjacent circles should be a prime.Note: the n

2014-11-23 21:26:52 271

原创 HDU 1242 Rescue(广搜)

题目概述:Angel was caught by the MOLIGPY! He was put in prison by Moligpy. The prison is described as a N * M (N, M Angel's friends want to save Angel. Their task is: approach Angel. We assume that

2014-11-23 21:18:33 340

原创 HDU 1026 Ignatius and the Princess I(广搜)

题目概述:The Princess has been abducted by the BEelzebub feng5166, our hero Ignatius has to rescue our pretty Princess. Now he gets into feng5166's castle. The castle is a large labyrinth. To make the p

2014-11-23 21:16:17 242

原创 HDU 1312 Red and Black(深搜)

题意:There is a rectangular room, covered with square tiles. Each tile is colored either red or black. A man is standing on a black tile. From a tile, he can move to one of four adjacent tiles. But he

2014-11-16 17:39:41 296

原创 HDU 1241 Oil Deposits(深搜)

题意:The GeoSurvComp geologic survey company is responsible for detecting underground oil deposits. GeoSurvComp works with one large rectangular region of land at a time, and creates a grid that divid

2014-11-16 17:31:31 267

原创 HDU 1010 Tempter of the Bone(深搜)

题意:Input:

2014-11-16 17:23:58 246

原创 HDU 1047 大数相加

题意:Input:The input will consist of at most 100 lines of text, each of which contains a single VeryLongInteger. Each VeryLongInteger will be 100 or fewer characters in length, and will only contain

2014-11-09 22:28:20 274

原创 POJ 2560 Freckles(最小生成树)

题目大意:有n个点,并且知道它们的坐标,求连接所有点的最短路径。 题目分析:v算法:prime算法v1.任选一个点,加入树中,作为第一个树中的点。 v2.取距离现有树距离最小的点,加入树中。v3.重复步骤2, 直至所有点都加入到树中。

2014-11-09 22:22:56 349

原创 POJ 2528 Mayor's posters(线段树)

题目大意:在墙壁上贴广告,广告的版面有大有小,并且贴广告有先后之分,后面贴的广告会覆盖前面的广告,求解最后能看到的广告面

2014-11-09 22:21:04 382

原创 HDU 3308 LCIS(线段树)

题目:Input:T in the first line, indicating the case number.Each case starts with two integers n , m(05).The next line has n integers(05).The next m lines each has an operation:U A B(05)OR

2014-11-02 21:47:47 241

原创 HDU 3577 Fast Arrangement(线段树)

题意:input:The input contains servel test cases. The first line is the case number. In each test case:The first line contains just one number k( 1 ≤ k ≤ 1000 ) and Q( 1 ≤ Q ≤ 100000 )The following

2014-11-02 00:32:18 270

原创 HDU 1166 排兵布阵(线段树)

题意:第一行一个整数T,表示有T组数据。每组数据第一行一个正整数N(N接下来每行有一条命令,命令有4种形式:(1) Add i j,i和j为正整数,表示第i个营地增加j个人(j不超过30)(2)Sub i j ,i和j为正整数,表示第i个营地减少j个人(j不超过30);(3)Query i j ,i和j为正整数,i(4)End 表示结束,这条命令在每组数据最后出现;每组

2014-11-01 17:01:05 352

原创 HDU 1233 还是畅通工程(并查集)

题意:某省调查乡村交通状况,得到的统计表中列出了任意两村庄间的距离。省政府“畅通工程”的目标是使全省任何两个村庄间都可以实现公路交通(但不一定有直接的公路相连,只要能间接通过公路可达即可),并要求铺设的公路总长度为最小。请计算最小的公路总长度。测试输入包含若干测试用例。每个测试用例的第1行给出村庄数目N ( 当N为0时,输入结束,该用例不被处理。

2014-10-26 19:50:22 306

原创 HDU 1232 畅通工程(最小生成树)

题目:某省调查城镇交通状况,得到现有城镇道路统计表,表中列出了每条道路直接连通的城镇。省政府“畅通工程”的目标是使全省任何两个城镇间都可以实现交通(但不一定有直接的道路相连,只要互相间接通过道路可达即可)。问最少还需要建设多少条道路?  Input测试输入包含若干测试用例。每个测试用例的第1行给出两个正整数,分别是城镇数目N ( 注意:两个城市之间可以有

2014-10-26 16:11:56 219

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除