自定义博客皮肤VIP专享

*博客头图:

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

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

博客底图:

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

栏目图:

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

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

深秋无痕

新手自编,不喜勿喷。。。

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

原创 ZOJ 1406 Jungle Roads

Jungle Roads题目传送门~Time Limit: 2000 msMemory Limit: 65536 KBThe Head Elder of the tropical island of Lagrishan has a problem. A burst of foreign aid money was spent on extra roads between villages some years ago. But the jungle overtakes roads re.

2020-06-26 23:30:22 302

原创 ZOJ 2451 Minimizing maximizer(点线段树维护查询+dp思想)

Minimizing maximizer题目传送门~Time Limit: 5000 msMemory Limit: 32768 KBThe company Chris Ltd. is preparing a new sorting hardware called Maximizer. Maximizer has N inputs numbered from 1 to N. Each input represents one integer. Maximizer has one output w

2020-06-26 16:36:31 987 1

原创 ZOJ 1610 Count the Colors(线段树经典)

Count the ColorsTime Limit: 2000 msMemory Limit: 65536 KBPainting some colored segments on a line, some previously painted segments may be covered by some the subsequent ones.Your task is counting the segments of different colors you can see at last.

2020-06-22 15:49:42 484

原创 ZOJ 1805 Squadtrees(四分树难题)

Squadtrees题目传送门~Time Limit: 5000 msMemory Limit: 32768 KBQuadtrees are data structures used to store digital images. For our purposes, the images will be simple bitmaps, where every pixel is either a 1 (black) or a 0 (white). A quadtree representatio

2020-06-20 20:58:39 915 1

原创 ZOJ 1788 Quad Trees (四分树经典)

Quad Trees题目传送门~Time Limit: 2000 msMemory Limit: 65536 KBA binary image, such as the one shown in Figure 2(a), is usually represented as an array of binary entries, i.e., each entry of the array has value 0 or 1. Figure 2(b) shows the array that repr

2020-06-20 14:58:15 745

原创 ZOJ 2833 Friendship(并查集)

FriendshipTime Limit: 3000 msMemory Limit: 32768 KBA friend is like a flower, a rose to be exact, Or maybe like a brand new gate that never comes unlatched. A friend is like an owl, both beautiful and wise. Or perhaps a friend is like

2020-06-18 12:20:07 413

原创 ZOJ 1789 The Suspects(经典并查集)

The Suspects题目传送门~Time Limit: 2000 msMemory Limit: 65536 KBSevere acute respiratory syndrome (SARS), an atypical pneumonia of unknown aetiology, was recognized as a global threat in mid-March 2003. To minimize transmission to others, the best strateg

2020-06-10 11:15:58 320

原创 POJ 2503 Babelfish(map)

Babelfish题目传送门~Time Limit:3000MS Memory Limit:65536K Total Submissions:56564 Accepted:23224 DescriptionYou have just moved from Waterloo to a big city. The people here speak an incomprehensible dialect of a foreign language. F...

2020-06-07 13:47:56 472

原创 ZOJ1383 Binary Numbers

Binary Numbers题目传送门~Time Limit: 2000 msMemory Limit: 65536 KBGiven a positive integer n, print out the positions of all 1's in its binary representation. The position of the least significant bit is 0.ExampleThe positions of 1's in the binary repr

2020-06-06 18:26:58 248

原创 ZOJ 2812 Quicksum

Quicksum题目传送门~Time Limit: 2000 msMemory Limit: 65536 KBA checksum is an algorithm that scans a packet of data and returns a single number. The idea is that if the packet is changed, the checksum will also change, so checksums are often used for detec

2020-06-05 19:02:41 296

原创 ZOJ1002 Fire Net

!!!写在前面的话语(泪水):①大家一定要注意if/else嵌套时尽量不要省略大括号呀,哭辽...搞了三个小时没看出来死在哪嘤嘤嘤②用除法定行数记得一定要注意换行位置的分类呀。。。容易死人!!!③感谢今天为我做饭提供做题能量的妈妈,感谢我的狗狗开心,她是最早看出来我不开心安慰我的(其实是自己安慰自己的叭hhhhhhh)。④谢谢今晚将好运赐予我的桐桐,今天晚上搞这个该死的水题惹我的宝贝儿生气了,对不起!!!Fire Net题目传送门Time Limit: 2000 msMemory

2020-05-30 23:21:19 255

原创 ZOJ 1091 Knight Moves(BFS)

Knight MovesTime Limit: 2000 msMemory Limit: 65536 KBA friend of you is doing research on theTraveling Knight Problem (TKP)where you are to find the shortest closed tour of knight moves that visits each square of a given set ofnsquares on a chessbo...

2020-05-28 19:30:18 233

原创 数字黑洞的验证

#include<iostream>using namespace std;int max_min(int x){ int a[5]; a[0]=x%10;x/=10; a[1]=x%10;x/=10; a[2]=x%10;x/=10; a[3]=x; int i,j,flag,temp; int max,min; int n; for(i=0;i&l...

2019-03-07 13:30:39 618 1

原创 一只小蜜蜂

一只小蜜蜂...Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 105860 Accepted Submission(s): 37417注:蜜蜂只能爬向右侧,不能反向爬,请编程计算从蜂巢a到b的可能路线。Input...

2019-03-05 11:26:51 297

原创 分离整数的各个数

   1088:分离整数的各个数 时间限制: 1000 ms         内存限制: 65536 KB 提交数: 7658     通过数: 5651  【题目描述】 给定一个整数n(1≤n≤100000000),要求从个位开始分离出它的每一位数字。从个位开始按照从低位到高位的顺序依次输出每一位数字。 【输入】 输入一个整数,整数...

2018-12-30 20:15:08 5217

原创 单词替换(字符数组操作)

1406:单词替换时间限制: 1000 ms         内存限制: 65536 KB提交数: 1982     通过数: 1161 【题目描述】输入一个字符串,以回车结束(字符串长度≤200)。该字符串由若干个单词组成,单词之间用一个空格隔开,所有单词区分大小写。现需要将其中的某个单词替换成另一个单词,并输出替换之后的字符串。【输入】第1行是包含多个单词的字符串 s;...

2018-12-01 18:18:24 796

原创 区间内的真素数

1411:区间内的真素数时间限制: 1000 ms         内存限制: 65536 KB提交数: 3319     通过数: 1382 【题目描述】找出正整数M和N之间(N不小于M)的所有真素数。真素数的定义:如果一个正整数P为素数,且其反序也为素数,那么P就为真素数。例如,11,13均为真素数,因为11的反序还是为11,13的反序为31也为素数。【输入】输...

2018-12-01 15:48:29 1054

原创 最长最短单词

1143:最长最短单词时间限制: 1000 ms         内存限制: 65536 KB提交数: 5553     通过数: 1929 【题目描述】 输入1行句子(不多于200个单词,每个单词长度不超过100),只包含字母、空格和逗号。单词由至少一个连续的字母构成,空格和逗号都是单词间的间隔。 试输出第1个最长的单词和第1个最短单词。 【输入】一行句子。【...

2018-11-30 21:13:52 1375

原创 整理药名

1139:整理药名时间限制: 1000 ms         内存限制: 65536 KB提交数: 4584     通过数: 2312 【题目描述】医生在书写药品名的时候经常不注意大小写,格式比较混乱。现要求你写一个程序将医生书写混乱的药品名整理成统一规范的格式,即药品名的第一个字符如果是字母要大写,其他字母小写。如将ASPIRIN、aspirin整理成Aspirin。【输入...

2018-11-30 16:22:18 796

原创 加密的病历单

1137:加密的病历单 时间限制: 1000 ms         内存限制: 65536 KB 提交数: 4706     通过数: 2439  【题目描述】  小英是药学专业大三的学生,暑假期间获得了去医院药房实习的机会。  在药房实习期间,小英扎实的专业基础获得了医生的一致好评,得知小英在计算概论中取得过好成绩后,主任又额外交给她一项任务,解...

2018-11-30 15:30:28 2070

原创 输出亲朋字符串

1133:输出亲朋字符串时间限制: 1000 ms         内存限制: 65536 KB提交数: 3713     通过数: 2775 【题目描述】编写程序,求给定字符串s的亲朋字符串s1。   亲朋字符串s1定义如下:给定字符串s的第一个字符的ASCII值加第二个字符的ASCII值,得到第一个亲朋字符; 给定字符串s的第二个字符的ASCII值加第三个字符的ASCII值...

2018-11-30 09:26:42 1713

原创 石头剪子布

1132:石头剪子布时间限制: 1000 ms         内存限制: 65536 KB提交数: 6448     通过数: 3325 【题目描述】石头剪子布,是一种猜拳游戏。起源于中国,然后传到日本、朝鲜等地,随着亚欧贸易的不断发展它传到了欧洲,到了近现代逐渐风靡世界。简单明了的规则,使得石头剪子布没有任何规则漏洞可钻,单次玩法比拼运气,多回合玩法比拼心理博弈,使得石头剪子布...

2018-11-29 20:57:31 1724

原创 计算鞍点

1122:计算鞍点时间限制: 1000 ms         内存限制: 65536 KB提交数: 5366     通过数: 3047 【题目描述】给定一个5*5的矩阵,每行只有一个最大值,每列只有一个最小值,寻找这个矩阵的鞍点。鞍点指的是矩阵中的一个元素,它是所在行的最大值,并且是所在列的最小值。   例如:在下面的例子中(第4行第1列的元素就是鞍点,值为8 )。11 ...

2018-11-28 17:52:32 2402

原创 矩阵乘法

#includeusing namespace std;int main(){int a[102][102]={0};int b[102][102]={0};int c[102][102]={0};int i;int j;int x;int n;int m;int p;cin>>m&

2018-11-28 16:22:18 670

空空如也

空空如也

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

TA关注的人

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