自定义博客皮肤VIP专享

*博客头图:

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

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

博客底图:

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

栏目图:

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

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

Dillonh的博客

励志成为一名优秀的数学选手!(博客园地址:http://www.cnblogs.com/Dillonh/)

  • 博客(18)
  • 收藏
  • 关注

原创 口算训练(唯一分解定理 + 二分+2018年女生赛)

题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=6287题目:口算训练Time Limit: 8000/4000 MS (Java/Others)    Memory Limit: 512000/512000 K (Java/Others)Total Submission(s): 177    Accepted Submission(s): 41Pro...

2018-05-29 14:51:28 403

原创 Codeforces Round #484 (Div. 2)

题目链接:http://codeforces.com/contest/982A. Rowtime limit per test:1 secondmemory limit per test:256 megabytesinput:standard inputoutput:standard outputYou're given a row with nn chairs. We call a seatin...

2018-05-18 17:40:51 221

原创 Codeforces Round #483 (Div. 2) [Thanks, Botan Investments and Victor Shaburov!]

题目链接:http://codeforces.com/contest/984A. Gametime limit per test:2 secondsmemory limit per test:512 megabytesinput:standard inputoutput:standard outputTwo players play a game.Initially there are nn in...

2018-05-16 19:07:50 423

原创 Codeforces Round #482 (Div. 2) B题

B. Treasure Hunt time limit per test1 second memory limit per test:256 megabytes input:standard input output:standard output After the big birthday party, Katie still wanted Shiro to have some mo...

2018-05-15 19:59:56 277

转载 sumblime快捷键

原文地址:https://blog.csdn.net/shutfuckingup/article/details/23846603 Ctrl+D 选词 (反复按快捷键,即可继续向下同时选中下一个相同的文本进行同时编辑)Ctrl+G 跳转到相应的行Ctrl+J 合并行(已选择需要合并的多行时)Ctrl+L 选择整行(按住-继续...

2018-05-15 19:23:59 949

原创 max_element和min_element的用法

首先,max_element和min_elemetn看字面意思是求最大值和最小值,这个确实是这个意思。不过,需要注意的是,他返回的是最大值(最小值)的地址,而非最大值(最小值)。对于一般数组的用法则是int pos = max_element(a, a + n) - a,min_element同理。对于vector则是int pos = max_element(v.begin(), v.end()...

2018-05-15 18:32:14 892

原创 2017 ACM-ICPC 亚洲区(乌鲁木齐赛区)网络赛 H. Skiing (拓扑排序+假dp)

题目链接:https://nanti.jisuanke.com/t/16957题目:In this winter holiday, Bob has a plan for skiing at the mountain resort.This ski resort has MMM different ski paths and NNN different flags situated at those...

2018-05-07 21:46:08 229

原创 逃生(HDU4857 + 反向拓扑排序)

题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=4857题面是中文题面,就不解释题意了,自己点击链接去看下啦~这题排序有两个条件,一个是按给定的那个序列(即输入的u,v,优先级最高),一个是序号从小到大(优先级次之)。正向的话由于这两个条件不好维护,所以就想着用反向拓扑排序来实现。首先记录每个节点的出度,然后用优先队列来维护顺序(使用默认的从大到小排序...

2018-05-07 19:54:30 404

原创 hihoCoder 1174 : 拓扑排序·一

题目链接:http://hihocoder.com/problemset/problem/1174题目是中文题面我就不说题意了,要看题面的请点击上方链接~代码实现如下: 1 #include <queue> 2 #include <cstdio> 3 #include <vector> 4 #include <algorithm> 5 usi...

2018-05-07 17:43:36 180

原创 取(m堆)石子游戏 HDU2176(Nim博弈)

题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=2176题目:Problem Descriptionm堆石子,两人轮流取.只能在1堆中取.取完者胜.先取者负输出No.先取者胜输出Yes,然后输出怎样取子.例如5堆 5,7,8,9,10先取者胜,先取者第1次取时可以从有8个的那一堆取走7个剩下1个,也可以从有9个的中那一堆取走9个剩下0个,也可以从有10...

2018-05-05 22:14:24 258

原创 Brave Game HDU1846(巴什博弈)

题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=1846题目:Problem Description十年前读大学的时候,中国每年都要从国外引进一些电影大片,其中有一部电影就叫《勇敢者的游戏》(英文名称:Zathura),一直到现在,我依然对于电影中的部分电脑特技印象深刻。今天,大家选择上机考试,就是一种勇敢(brave)的选择;这个短学期,我们讲的是博...

2018-05-05 22:03:53 257

原创 取石子游戏 HDU2516(斐波那契博弈)

题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=2516题目:Problem Description1堆石子有n个,两人轮流取.先取者第1次可以取任意多个,但不能全部取完.以后每次取的石子数不能超过上次取子数的2倍。取完者胜.先取者负输出"Second win".先取者胜输出"First win". Input输入有多组.每组第1行是2<=n&l...

2018-05-05 22:00:48 355

原创 2018年北京信息科技大学第十届程序设计竞赛暨ACM选拔赛 E-233

题目链接:https://www.nowcoder.com/acm/contest/118/E看到大数直接套JAVA,但是后面MekakuCityActors大佬和我说可以找规律(>_<),仔细想想确实可以,下面是我的java实现代码:import java.math.BigInteger;import java.util.Scanner;public class Main {...

2018-05-05 16:04:26 249

原创 新疆大学ACM-ICPC程序设计竞赛五月月赛(同步赛) F.猴子排序的期望

题目链接:https://www.nowcoder.com/acm/contest/116/F题目描述我们知道有一种神奇的排序方法叫做猴子排序,就是把待排序的数字写在卡片上,然后让猴子把卡片扔在空中,等落下的时候观察这些卡片是否从左到右已经排序完成(我们认为不会发生卡片落地后叠在一起的情况)如果有序则排序完成,否则让猴子再扔一遍,直到卡片有序,那么问题来了,给你N个卡片,每个卡片上写着一个大写字母...

2018-05-04 17:45:28 232

原创 CRB and Candies(组合数学+求逆元+lcm)

题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=5407题目:Problem DescriptionCRB has N different candies. He is going to eat K candies.He wonders how many combinations he can select.Can you answer his que...

2018-05-04 14:51:55 277

原创 Codeforces Round #478 (Div. 2)

题目链接:http://codeforces.com/contest/975 A. Aramic scripttime limit per test:1 secondmemory limit per test:256 megabytesinput:standard inputoutput:standard outputIn Aramic language words can only repres...

2018-05-03 00:40:48 387

原创 Educational Codeforces Round 43 (Rated for Div. 2)

题目链接:http://codeforces.com/contest/976 A. Minimum Binary Numbertime limit per test:1 secondmemory limit per test:256 megabytesinput:standard inputoutput:standard outputString can be called correct if ...

2018-05-02 19:53:52 280

原创 Fire! (双bfs+预处理)

题目链接:https://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&page=show_problem&problem=2671题目:Joe works in a maze. Unfortunately, portions of the maze have caught on fire, and...

2018-05-01 11:27:01 201

空空如也

空空如也

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

TA关注的人

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