自定义博客皮肤VIP专享

*博客头图:

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

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

博客底图:

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

栏目图:

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

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

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

原创 HDU-1213 How Many Tables(并查集基础)

Today is Ignatius' birthday. He invites a lot of friends. Now it's dinner time. Ignatius wants to know how many tables he needs at least. You have to notice that not all the friends know each other, a...

2018-12-26 09:41:38 283

原创 HDU-1272 小希的迷宫(并查集)

上次Gardon的迷宫城堡小希玩了很久(见Problem B),现在她也想设计一个迷宫让Gardon来走。但是她设计迷宫的思路不一样,首先她认为所有的通道都应该是双向连通的,就是说如果有一个通道连通了房间A和B,那么既可以通过它从房间A走到房间B,也可以通过它从房间B走到房间A,为了提高难度,小希希望任意两个房间有且仅有一条路径可以相通(除非走了回头路)。小希现在把她的设计图给你,让你帮忙判断她的...

2018-12-26 09:23:15 273

原创 UVA-10325 The Lottery(二进制状态枚举)

The Sports Association of Bangladesh is in great problem with their latest lottery ‘Jodi laiga Jai’. There are so many participants this time that they cannot manage all the numbers. In an urgent meet...

2018-12-02 18:59:55 417

原创 HDU-4709 Herding

Little John is herding his father's cattles. As a lazy boy, he cannot tolerate chasing the cattles all the time to avoid unnecessary omission. Luckily, he notice that there were N trees in the meadow ...

2018-12-02 07:52:51 420

原创 UVA-11582 Colossal Fibonacci Numbers!(斐波那契循环节)

The i’th Fibonacci number f(i) is recursively defined in the following way:       • f(0) = 0 and f(1) = 1       • f(i + 2) = f(i + 1) + f(i) for every i ≥ 0       Your task is to compute some value...

2018-12-02 07:43:00 236

原创 HDU-2391 Filthy Rich(简单DP)

They say that in Phrygia, the streets are paved with gold. You’re currently on vacation in Phrygia, and to your astonishment you discover that this is to be taken literally: small heaps of gold are di...

2018-12-02 07:19:18 230

原创 UVA-294 Divisors(线性筛+唯一分解定理)

Mathematicians love all sorts of odd properties of numbers. For instance, they consider 945 to be an interesting number, since it is the first odd number for which the sum of its divisors is larger th...

2018-12-02 07:11:55 533

原创 HDU-2062 Subset sequence

Consider the aggregate An= { 1, 2, …, n }. For example, A1={1}, A3={1,2,3}. A subset sequence is defined as a array of a non-empty subset. Sort all the subset sequece of An in lexicography order. Your...

2018-12-01 11:37:03 304

原创 HDU-1260 Tickets(简单DP)

Jesus, what a great movie! Thousands of people are rushing to the cinema. However, this is really a tuff time for Joe who sells the film tickets. He is wandering when could he go back home as early as...

2018-11-28 17:04:18 450

原创 HDU-2674 N!Again

WhereIsHeroFrom:             Zty, what are you doing ?  Zty:                                     I want to calculate N!......  WhereIsHeroFrom:             So easy! How big N is ?  Zty:               ...

2018-11-28 16:31:57 239

原创 HDU-1212 Big Number(同余定理)

As we know, Big Number is always troublesome. But it's really important in our ACM. And today, your task is to write a program to calculate A mod B.  To make the problem easier, I promise that B will ...

2018-11-28 16:19:53 233

原创 UVA-11827 Maximum GCD(辗转相除法求GCD)

Given the N integers, you have to find the maximum GCD (greatest common divisor) of every possible pair of these integers. Input The first line of input is an integer N (1 < N < 100) that dete...

2018-11-28 15:58:36 349

原创 HDU-1016 Prime Ring Problem

DescriptionA 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 ...

2018-03-30 19:23:36 274

原创 HDU-1241 Oil Deposits(简单DFS)

DescriptionThe 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...

2018-03-30 18:39:57 338 1

原创 HDU - 2124 Repair The Wall (贪心水题)

DescriptionLong time ago , Kitty lived in a small village. The air was fresh and the scenery was very beautiful. The only thing that troubled her is the typhoon. When the typhoon came, everything is t...

2018-03-28 19:27:37 360

空空如也

空空如也

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

TA关注的人

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