自定义博客皮肤VIP专享

*博客头图:

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

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

博客底图:

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

栏目图:

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

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

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

原创 codeforces——1455 A-E

Educational Codeforces Round 99 (Rated for Div. 2)A. Strange FunctionsB. JumpsC. Ping-pongD. Sequence and SwapsE. Four PointsA. Strange Functions水 for i in range(int(input())): m = input() print(len(m))B. Jumps找规律,列出

2020-12-11 17:37:57 144

原创 codeforces——1016

Table of Contentscodeforces----1016codeforces----1016Acodeforces----1016Bcodeforces----1016Ccodeforces----1016Dcodeforces----1016Ecodeforces----1016codeforces----1016Ahttp://codeforc...

2018-08-20 10:37:48 359

原创 2018百度之星程序设计大赛资格赛

http://acm.hdu.edu.cn/showproblem.php?pid=6344注意优化#include<iostream>#include<algorithm>#include<cstring>#include<map>#include<cstdio>using namespace std;int ma...

2018-08-08 14:05:24 220

原创 计蒜客————取数游戏

https://nanti.jisuanke.com/t/48有如下一个双人游戏:N个正整数的序列放在一个游戏平台上,两人轮流从序列的两端取数,每次有数字被一个玩家取走后,这个数字被从序列中去掉并累加到取走该数的玩家的得分中,当数取尽时,游戏结束。以最终得分多者为胜。编一个执行最优策略的程序,最优策略就是使自己能得到在当前情况下最大的可能的总分的策略。你的程序要始终为两位玩家执行最优策略。...

2018-08-03 11:13:42 417

原创 codeforces——1015

Table of Contentscodeforces----1015codeforces----1015Acodeforces----1015Bcodeforces----1015Ccodeforces----1015Dcodeforces----1015Ecodeforces----1015Fcodeforces----1015codeforces----1...

2018-08-03 08:45:10 595

原创 codeforces——1010

Table of Contentscodeforces----1010codeforces----1010Acodeforces----1010Ccodeforces----1010Dcodeforces----1010Ahttp://codeforces.com/problemset/problem/1010/A有n个星球,每个星球具有两个属性:飞行燃油比,降落燃油比...

2018-08-01 14:35:30 245

原创 POJ - 1204 -Word Puzzles

http://poj.org/problem?id=1204ac 自动机。。将关键字建树。#include<iostream>#include<algorithm>#include<cstring>#include<queue>#include<set>#include<cstdio>using namespace...

2018-04-22 21:08:40 260

原创 HDU - 2222——Keywords Search

http://acm.hdu.edu.cn/showproblem.php?pid=2222T个测试数据,n个关键字,问所给字符串出现了哪几种关键字。HDU的测试数据比较弱,提供一组数据12sherhesher输出 2.ac代码。#include<iostream>#include<algorithm>#include<cstring>#inclu...

2018-04-21 11:17:04 335

原创 codeforces——962

http://codeforces.com/problemset/problem/962/A当前缀最短是多长时,前缀和为全串和的一半以上#include <cstring>#include <queue>#include <cstdio>#include <algorithm>#include <string>#include ...

2018-04-15 21:04:24 400

原创 第13届景驰-埃森哲杯广东工业大学ACM程序设计大赛

https://www.nowcoder.com/acm/contest/90#questionA#include <cstring>#include <queue>#include <cstdio>#include <algorithm>#include <string>#include <map>#includ...

2018-03-27 19:56:23 145

原创 牛客网----Wannafly挑战赛12

https://www.nowcoder.com/acm/contest/79#questionA题,简单的递归https://www.nowcoder.com/acm/contest/79/A#include <cstring>#include <queue>#include <cstdio>#include <algorithm>#inc...

2018-03-23 20:39:23 204

原创 HDU - 1305——Immediate Decodability

Immediate DecodabilityTime Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 4002    Accepted Submission(s): 2100Problem DescriptionAn encoding of a se...

2018-03-21 16:41:34 157

原创 HDU - 1711——Number Sequence

Number SequenceTime Limit: 10000/5000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 34455    Accepted Submission(s): 14320Problem DescriptionGiven two sequences of ...

2018-03-21 16:04:49 168

原创 牛客网----Wannafly挑战赛9

https://www.nowcoder.net/acm/contest/71#questionhttps://www.nowcoder.net/acm/contest/71/A给定n个正整数,请找出其中有多少个数x满足:在这n个数中存在数y=kx,其中k为大于1的整数本题是类似于素数筛法的算法,代码比较容易理解#include<cstring>#include<iostrea...

2018-02-10 19:57:00 224

原创 HDU - 6253——Knightmare

KnightmareTime Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/65536 K (Java/Others)Total Submission(s): 346    Accepted Submission(s): 144Problem DescriptionA knight jumps ar

2018-02-01 16:48:29 355

原创 2017-2018 ACM-ICPC, NEERC, Southern Subregional Contest (Online Mirror, ACM-ICPC Rules, Teams Prefer

E. Field of Wonders#include#include#include#include#includeusing namespace std;int main() { int n; char s[52]; while ( cin >> n >> s ) { bool know[26] = {}; for

2017-11-20 19:59:43 256

原创 POJ - 2528 - Mayor's posters

Mayor's postersTime Limit: 1000MS Memory Limit: 65536KTotal Submissions: 70551 Accepted: 20345DescriptionThe citizens of Bytetown, AB, could not stand that the ca

2017-11-12 14:17:12 188

原创 计蒜客————King's Heir

56.93% 2000ms 262144KThe king is dead, long live the king! After the sudden death of the king Fert XIII the people of theFlatland Kingdom are going to welcome the new king. Unfortu

2017-11-01 14:11:44 366

原创 计蒜客————Folding

30.64% 2000ms 262144KAs you can remember, Alex is fond of origami. She switched from squares to rectangles, and rectangles are much more difficult to master. Her main interest is t

2017-10-30 19:34:40 279

原创 计蒜客————Anniversary Cake

21.08% 2000ms 262144KTwo students, Adam and Anton, are celebrating two-year anniversary of not passing their Math Logic exam. After very careful search in a local supermarket, they

2017-10-29 10:39:42 319

原创 计蒜客————Jumbled Compass

65.23% 1000ms 65536KJonas is developing the JUxtaPhone and is tasked with animating the compass needle. The API is simple: the compass needle is currently in some direction (betwee

2017-10-29 09:49:32 432

原创 计蒜客————Game Rank

26.32% 1000ms 65536KThe gaming company Sandstorm is developing an online two player game. You have been asked to implement the ranking system. All players have a rank determining t

2017-10-29 09:13:48 302

原创 计蒜客————Daydreaming Stockbroker

28.91% 1000ms 65536KGina Reed, the famous stockbroker, is having a slow day at work, and between rounds of solitaire she is day-dreaming. Foretelling the future is hard, but imagin

2017-10-27 20:29:57 628

原创 codeforces——875B —— Sorting the Coins

B. Sorting the Coinstime limit per test1 secondmemory limit per test512 megabytesinputstandard inputoutputstandard outputRecently, Dima met with Sasha in a phil

2017-10-23 20:34:26 256

原创 codeforces——875A —— Classroom Watch

A. Classroom Watchtime limit per test1 secondmemory limit per test512 megabytesinputstandard inputoutputstandard outputEighth-grader Vova is on duty today in th

2017-10-23 20:30:56 427

原创 计蒜客————无脑博士的试管们

17.62% 1000ms 65536K无脑博士有三个容量分别是 A,B,CA,B,C 升的试管,A,B,CA,B,C 分别是三个从 11 到 2020 的整数,最初,AA 和 BB 试管都是空的,而 CC 试管是装满硫酸铜溶液的。有时,无脑博士把硫酸铜溶液从一个试管倒到另一个试管中,直到被灌试管装满或原试管空了。当然每一次灌注都是完全的。由于无脑博士天天这么折腾,

2017-10-20 20:19:45 1338

原创 计蒜客————跳跃游戏二

30.18% 1000ms 65536K给定一个非负整数数组,假定你的初始位置为数组第一个下标。数组中的每个元素代表你在那个位置能够跳跃的最大长度。你的目标是到达最后一个下标,并且使用最少的跳跃次数。例如:A = [2,3,1,1,4]A=[2,3,1,1,4],到达最后一个下标的最少跳跃次数为 22。(先跳跃 11 步,从下标 00 到 11,

2017-10-18 20:37:31 247

原创 计蒜客————爬楼梯

31.15% 1000ms 65536K假设你现在正在爬楼梯,楼梯有 nn 级。每次你只能爬 11 级或者 22 级,那么你有多少种方法爬到楼梯的顶部?输入格式第一行输入一个整数 n(1\leq n \leq 50)n(1≤n≤50),代表楼梯的级数。输出格式输出爬到楼梯顶部的方法总数。样例输入5样例输

2017-10-18 16:43:44 942

原创 计蒜客————等和的分隔子集

23.89% 1000ms 65536K晓萌希望将1到N的连续整数组成的集合划分成两个子集合,且保证每个集合的数字和是相等。例如,对于N=3,对应的集合{1,2,3}能被划分成{3} 和 {1,2}两个子集合.这两个子集合中元素分别的和是相等的。对于N=3,我们只有一种划分方法,而对于N=7时,我们将有4种划分的方案。输入包括一行,仅一个整数,表示N的值(1≤N

2017-10-18 15:58:11 245

原创 codeforces——873C —— Strange Game On Matrix

C. Strange Game On Matrixtime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputIvan is playing a strange game.

2017-10-13 19:17:48 578

原创 codeforces——873B —— Balanced Substring

B. Balanced Substringtime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputYou are given a string s consisting on

2017-10-13 18:17:22 454

原创 codeforces——873A —— Chores

A. Chorestime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputLuba has to do n chores today. i-th chore takes

2017-10-13 13:59:39 640

原创 codeforces—— 869E —— The Untended Antiquity

E. The Untended Antiquitytime limit per test2 secondsmemory limit per test512 megabytesinputstandard inputoutputstandard outputAdieu l'ami.Koyomi is helping

2017-10-12 20:55:02 361

原创 codeforces—— 869C —— The Intriguing Obsession

C. The Intriguing Obsessiontime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard output— This is not playing but duty a

2017-10-12 19:26:00 335

原创 codeforces—— 869B —— The Eternal Immortality

B. The Eternal Immortalitytime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputEven if the world is full of coun

2017-10-11 16:19:33 243

原创 codeforces—— 869A —— The Artful Expedient

A. The Artful Expedienttime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputRock... Paper!After Karen have f

2017-10-11 15:56:25 581

原创 POJ - 3630 - Phone List

Phone ListTime Limit: 1000MS Memory Limit: 65536KTotal Submissions: 31265 Accepted: 9188DescriptionGiven a list of phone numbers, determine if it is consistent in

2017-10-08 21:05:17 204

原创 POJ - 1014 - Dividing

DividingTime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 72353 Accepted: 18864DescriptionMarsha and Bill own a collection of marbles. They want to split

2017-10-07 09:18:38 222

原创 POJ - 1088 - 滑雪

滑雪Time Limit: 1000MS Memory Limit: 65536KTotal Submissions: 101113 Accepted: 38478DescriptionMichael喜欢滑雪百这并不奇怪, 因为滑雪的确很刺激。可是为了获得速度,滑的区域必须向下倾斜,而且当你滑到坡底,你不得不再次走上坡或者

2017-10-05 20:07:37 201

原创 HDU - 1556——Color the ball

Color the ballTime Limit: 9000/3000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 23610    Accepted Submission(s): 11476Problem DescriptionN个气球排成一排,

2017-10-05 12:15:46 203

空空如也

空空如也

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

TA关注的人

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