
基础dp
int_Brosea
CS and CS
展开
-
小小粉刷匠 牛客(区间dp)
链接:https://ac.nowcoder.com/acm/problem/16129来源:牛客网题目描述“lalala,我是一个快乐的粉刷匠”,小名一边快活地唱着歌,一边开心地刷着墙",兴致突然被打断,“小名,你今天如果刷不完这一栋楼的墙,那么你就等着被炒鱿鱼吧”,老板声嘶力竭的吼着。苦恼的小名因为不想被炒鱿鱼,所以希望尽量快地刷完墙,由于他本人的数学基础很差,他现在请你来帮助他计算最少...原创 2019-07-30 14:58:28 · 730 阅读 · 0 评论 -
Computer HDU 2196 (树形dp)
Computer HDU-2196Problem DescriptionA school bought the first computer some time ago(so this computer’s id is 1). During the recent years the school bought N-1 new computers. Each new computer was c...原创 2019-08-02 22:14:24 · 269 阅读 · 0 评论 -
sue的小球 牛客(区间dp)
链接:https://ac.nowcoder.com/acm/problem/20312来源:牛客网题目描述Sue和Sandy最近迷上了一个电脑游戏,这个游戏的故事发在美丽神秘并且充满刺激的大海上,Sue有一支轻便小巧的小船。然而,Sue的目标并不是当一个海盗,而是要收集空中漂浮的彩蛋,Sue有一个秘密武器,只要她将小船划到一个彩蛋的正下方,然后使用秘密武器便可以在瞬间收集到这个彩蛋。然而,...原创 2019-07-30 17:31:43 · 187 阅读 · 0 评论 -
涂色PAINT 牛客(区间dp,基础)
链接:https://ac.nowcoder.com/acm/problem/19909来源:牛客网题目描述假设你有一条长度为5的木版,初始时没有涂过任何颜色。你希望把它的5个单位长度分别涂上红、绿、蓝、绿、红色,用一个长度为5的字符串表示这个目标:RGBGR。 每次你可以把一段连续的木版涂成一个给定的颜色,后涂的颜色覆盖先涂的颜色。例如第一次把木版涂成RRRRR,第二次涂成RGGGR,第...原创 2019-07-30 19:41:42 · 531 阅读 · 0 评论 -
CF429B Working out(动态规划,四角dp)
Virtual Judge-CF429BSummer is coming! It’s time for Iahub and Iahubina to work out, as they both want to look hot at the beach. The gym where they go is a matrix a with n lines and m columns. Let num...原创 2019-07-26 13:41:09 · 386 阅读 · 0 评论 -
HDU - 1011 Starship Troopers (树形dp)
HDU1011You, the leader of Starship Troopers, are sent to destroy a base of the bugs. The base is built underground. It is actually a huge cavern, which consists of many rooms connected with tunnels. ...原创 2019-08-06 15:33:58 · 234 阅读 · 0 评论 -
CF-219D Choosing Capital for Treeland(树形dp)
CF-219D题目描述The country Treeland consists of n cities, some pairs of them are connected with unidirectional roads. Overall there are n - 1 roads in the country. We know that if we don’t take the dire...原创 2019-08-06 19:34:17 · 267 阅读 · 0 评论 -
HDU-2476 String Painter(区间dp)
HDU-2476问题描述There are two strings A and B with equal length. Both strings are made up of lower case letters. Now you have a powerful string painter. With the help of the painter, you can change a se...原创 2019-08-06 20:56:29 · 208 阅读 · 0 评论