搜索
wys5
加油
展开
-
Tempter of the Bone
Problem DescriptionThe doggie found a bone in an ancient maze, which fascinated him a lot. However, when he picked it up, the maze began to shake, and the doggie could feel the ground sinking. He re...原创 2019-02-28 20:50:52 · 132 阅读 · 0 评论 -
Asteroids!
Problem DescriptionYou're in space.You want to get home.There are asteroids.You don't want to hit them.InputInput to this problem will consist of a (non-empty) series of up to 100 data sets. ...原创 2019-08-10 16:07:10 · 154 阅读 · 0 评论 -
Oil Deposits
Problem 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...原创 2019-08-10 16:08:53 · 89 阅读 · 0 评论 -
Rescue
Problem DescriptionAngel was caught by the MOLIGPY! He was put in prison by Moligpy. The prison is described as a N * M (N, M <= 200) matrix. There are WALLs, ROADs, and GUARDs in the prison.Ang...原创 2019-08-10 16:10:19 · 89 阅读 · 0 评论 -
Knight Moves
Problem DescriptionA friend of you is doing research on the Traveling Knight Problem (TKP) where you are to find the shortest closed tour of knight moves that visits each square of a given set of...原创 2019-08-11 09:33:18 · 273 阅读 · 0 评论 -
Red and Black
Problem DescriptionThere is a rectangular room, covered with square tiles. Each tile is colored either red or black. A man is standing on a black tile. From a tile, he can move to one of four adjace...原创 2019-08-11 09:31:40 · 164 阅读 · 0 评论 -
幼儿园分班
链接:https://www.nowcoder.com/questionTerminal/e503f18d56754ad9bcf8631adf63721d来源:牛客网幼儿园一个大班要分成两个小班,有些小朋友不希望自己和其他某几位小朋友同班。园长向大家收集了不希望同班的要求,然后视情况将一个大班的小朋友分成两个班。请你开发一个程序,帮助园长快速判断是否所有小朋友的不同班请求都可以被满足。...原创 2019-05-13 19:28:02 · 2738 阅读 · 0 评论 -
1144F. Graph Without Long Directed Paths
题目链接:http://codeforces.com/problemset/problem/1144/F题意:给出n个顶点和m条边,找出是否存在有向图使得图中最大长度小于等于2.(可能存在两个或两个以上互不相连的图)分析:图着色问题: 1.当前节点涂色。 2.下一节点没涂色->dfs下一节点 3.下一节点有颜色->...原创 2019-04-02 19:58:32 · 227 阅读 · 0 评论 -
Nightmare
Problem DescriptionIgnatius had a nightmare last night. He found himself in a labyrinth with a time bomb on him. The labyrinth has an exit, Ignatius should get out of the labyrinth before the bomb e...原创 2019-03-08 19:36:52 · 566 阅读 · 0 评论 -
历届试题-分考场
问题描述 n个人参加某项特殊考试。 为了公平,要求任何两个认识的人不能分在同一个考场。 求是少需要分几个考场才能满足条件。输入格式 第一行,一个整数n(1<n<100),表示参加考试的人数。 第二行,一个整数m,表示接下来有m行数据 以下m行每行的格式为:两个整数a,b,用空格分开 (1<=a,b<=n) 表示第a个人与第b个人认识。输出...原创 2019-03-08 16:06:26 · 273 阅读 · 0 评论 -
Robot Motion
Problem DescriptionA robot has been programmed to follow the instructions in its path. Instructions for the next direction the robot is to move are laid down in a grid. The possible instructions ar...原创 2019-03-05 17:08:33 · 124 阅读 · 0 评论 -
PTA-L3-008 喊山
喊山,是人双手围在嘴边成喇叭状,对着远方高山发出“喂—喂喂—喂喂喂……”的呼唤。呼唤声通过空气的传递,回荡于深谷之间,传送到人们耳中,发出约定俗成的“讯号”,达到声讯传递交流的目的。原来它是彝族先民用来求援呼救的“讯号”,慢慢地人们在生活实践中发现了它的实用价值,便把它作为一种交流工具世代传袭使用。(图文摘自:http://news.xrxxw.com/newsshow-8018.html)...原创 2019-03-05 15:13:17 · 789 阅读 · 0 评论 -
Prime Ring Problem
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....原创 2019-03-01 20:53:43 · 727 阅读 · 0 评论 -
牛牛的背包问题
链接:https://www.nowcoder.com/questionTerminal/bf877f837467488692be703735db84e6来源:牛客网牛牛准备参加学校组织的春游, 出发前牛牛准备往背包里装入一些零食, 牛牛的背包容量为w。牛牛家里一共有n袋零食, 第i袋零食体积为v[i]。牛牛想知道在总体积不超过背包容量的情况下,他一共有多少种零食放法(总体积为0...原创 2019-08-17 22:57:06 · 135 阅读 · 0 评论