随笔分类 -  动态规划

摘要:Acesrc and Travel 题目描述 Acesrc is a famous tourist at Nanjing University second to none. During this summer holiday, he, along with Zhang and Liu, is g 阅读全文
posted @ 2019-08-18 10:16 1371767389 阅读(306) 评论(1) 推荐(0)
摘要:Nonsense Time 时间限制: 10 Sec 内存限制: 128 MB 题目描述 You a given a permutation p1,p2,…,pn of size n. Initially, all elements in p are frozen. There will be n 阅读全文
posted @ 2019-08-07 23:05 1371767389 阅读(281) 评论(0) 推荐(0)
摘要:independent set 1 时间限制:C/C++ 1秒,其他语言2秒空间限制:C/C++ 102400K,其他语言204800K64bit IO Format: %lld 题目描述 Note: For C++ languages, the memory limit is 100 MB. Fo 阅读全文
posted @ 2019-08-02 00:18 1371767389 阅读(663) 评论(0) 推荐(0)
摘要:拓扑序计数 时间限制: 1 s 空间限制: 128000 KB 拓扑序计数 时间限制: 1 s 拓扑序计数 时间限制: 1 s 空间限制: 128000 KB 空间限制: 128000 KB 空间限制: 128000 KB 题目描述 Description 求一颗有根树/树形图的拓扑序个数. 输入描 阅读全文
posted @ 2018-10-04 00:21 1371767389 阅读(582) 评论(0) 推荐(0)
摘要:特种部队 时间限制: 1 s 空间限制: 64000 KB 特种部队 特种部队 时间限制: 1 s 空间限制: 64000 KB 时间限制: 1 s 时间限制: 1 s 空间限制: 64000 KB 空间限制: 64000 KB 题目描述 Description 某特种部队接到一个任务,需要潜入一个 阅读全文
posted @ 2018-10-03 22:18 1371767389 阅读(193) 评论(0) 推荐(0)
摘要:最长不下降子序列问题 最长不下降子序列问题 最长不下降子序列问题 时空限制1000ms / 128MB 题目描述 «问题描述: 给定正整数序列x1,...,xn 。 (1)计算其最长不下降子序列的长度s。 (2)计算从给定的序列中最多可取出多少个长度为s的不下降子序列。 (3)如果允许在取出的序列中 阅读全文
posted @ 2018-09-27 18:29 1371767389 阅读(197) 评论(0) 推荐(0)
摘要:送外卖 时间限制: 2 s 空间限制: 256000 KB 送外卖 送外卖 时间限制: 2 s 空间限制: 256000 KB 时间限制: 2 s 时间限制: 2 s 空间限制: 256000 KB 空间限制: 256000 KB 题目描述 Description 有一个送外卖的,他手上有n份订单, 阅读全文
posted @ 2018-09-22 21:06 1371767389 阅读(585) 评论(1) 推荐(1)
摘要:Spell Boost 题目描述 Shadowverse is a funny card game. One day you are playing a round of this game.You have n cards, each with two attributes wi and xi. 阅读全文
posted @ 2018-09-06 00:31 1371767389 阅读(388) 评论(0) 推荐(0)
摘要:Bichrome Tree 题目描述 We have a tree with N vertices. Vertex 1 is the root of the tree, and the parent of Vertex i (2≤i≤N) is Vertex Pi.To each vertex in 阅读全文
posted @ 2018-08-03 20:16 1371767389 阅读(381) 评论(0) 推荐(0)
摘要:经营与开发 题目描述 4X概念体系,是指在PC战略游戏中一种相当普及和成熟的系统概念,得名自4个同样以“EX”为开头的英语单词。 eXplore(探索) eXpand(拓张与发展) eXploit(经营与开发) eXterminate(征服) ——维基百科 今次我们着重考虑exploit部分,并将其 阅读全文
posted @ 2018-07-24 19:11 1371767389 阅读(243) 评论(0) 推荐(0)
摘要:最短Hamilton路径 题目描述 给定一张 n(n≤20) 个点的带权无向图,点从 0~n-1 标号,求起点 0 到终点 n-1 的最短Hamilton路径。 Hamilton路径的定义是从 0 到 n-1 不重不漏地经过每个点恰好一次。 输入 第一行一个整数n。 接下来n行每行n个整数,其中第i 阅读全文
posted @ 2018-06-26 12:51 1371767389 阅读(1379) 评论(1) 推荐(0)