- 博客(12)
- 收藏
- 关注
原创 0、Get Start With C++
0、 前言经历了第一次正式比赛(2017JSCPC),深感基础的不扎实,写写这些东西,也权当是巩固一下基础了。首先,必须要声明,这个教程并不会面面俱到;但是作为入门是足够的。C++包罗万象,若是想要深入研究,推荐在学会我后面讲的各种内容之后,再去看看C++ Primer、Effective C++、Effective STL等书。其次,我默认此文的读者是学过C的,相关内容不会赘述。
2017-05-18 14:44:57
421
原创 POJ2236 Wireless Network(并查集)
Wireless NetworkTime Limit: 10000MS Memory Limit: 65536KTotal Submissions: 26818 Accepted: 11129DescriptionAn earthquake takes place in Southeast Asia. The ACM
2017-04-07 17:10:33
243
原创 POJ 1979 Red and Black (dfs)
Red and BlackTime Limit: 1000MS Memory Limit: 30000KTotal Submissions: 34821 Accepted: 18827DescriptionThere is a rectangular room, covered with square tiles. E
2017-04-07 17:07:41
212
原创 POJ 2243 Knight Moves (bfs)
Knight MovesTime Limit: 1000MS Memory Limit: 65536KTotal Submissions: 13925 Accepted: 7766DescriptionA friend of you is doing research on the Traveling Knight P
2017-04-07 16:50:02
258
原创 POJ 3258:River Hopscotch & POJ 3273:Monthly Expense (二分)
传送门:POJ 3258POJ 3273两道题思路差不了多少,找到要二分什么,怎么check,问题基本就解决了。River Hopscotch:#include #include #include #include #define eps 1e-7using namespace std;int l, n, m;int pos[50005];
2017-03-20 13:07:19
173
原创 POJ 3104 Drying
It is very hard to wash and especially to dry clothes in winter. But Jane is a very smart girl. She is not afraid of this boring process. Jane has decided to use a radiator to make drying faster. But
2017-03-20 12:57:17
175
原创 POJ 1700 Crossing River
DescriptionA group of N people wishes to go across a river with only one boat, which can at most carry two persons. Therefore some sort of shuttle arrangement must be arranged in order to row the
2017-03-12 20:46:48
165
原创 HDU 1789 Doing Homework again
Problem DescriptionIgnatius has just come back school from the 30th ACM/ICPC. Now he has a lot of homework to do. Every teacher gives him a deadline of handing in the homework. If Ignatius hands i
2017-03-12 20:35:32
165
原创 POJ 2376 Cleaning Shifts
DescriptionFarmer John is assigning some of his N (1 <= N <= 25,000) cows to do some cleaning chores around the barn. He always wants to have one cow working on cleaning things up and has divided
2017-03-12 20:25:53
170
原创 HDU2602 Bone Collector(DP)
Problem DescriptionMany years ago , in Teddy’s hometown there was a man who was called “Bone Collector”. This man like to collect varies of bones , such as dog’s , cow’s , also he went to the grave
2017-03-05 14:13:30
318
原创 HDU2571 命运(DP)
Problem Description穿过幽谷意味着离大魔王lemon已经无限接近了!可谁能想到,yifenfei在斩杀了一些虾兵蟹将后,却再次面临命运大迷宫的考验,这是魔王lemon设下的又一个机关。要知道,不论何人,若在迷宫中被困1小时以上,则必死无疑!可怜的yifenfei为了去救MM,义无返顾地跳进了迷宫。让我们一起帮帮执着的他吧!命运大迷宫可以看成是一个两维的方格阵列
2017-03-05 13:49:08
374
原创 UVA 10474 - Where is the Marble?
本题较为简单,就是先排个序,然后再搜索。读懂题目之后,做起来并不难。同时,通过使用STL容器及算法可以大大缩减所用时间。可以明显感受到C++之于C的优越性,其非常重要的一点便是它强大的标准库。不过粗心的我因为没有注意输出格式,而吃了一次WA……题目地址 代码如下:#include #include #include using namespace std;
2017-02-26 12:19:10
199
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人