链表
云淡风轻jzl
一路脚踏实地,不忘仰望星空。
展开
-
HDU 5009-Paint Pearls-dp+双向链表
DescriptionLee has a string of n pearls. In the beginning, all the pearls have no color. He plans to color the pearls to make it more fascinating. He drew his ideal pattern of the string on a paper a...原创 2019-08-27 15:59:48 · 185 阅读 · 0 评论 -
HDU 2181-哈密顿绕行世界问题-dfs+链表树存路径
题目描述:一个规则的实心十二面体,它的 20个顶点标出世界著名的20个城市,你从一个城市出发经过每个城市刚好一次后回到出发的城市。输入描述:前20行的第i行有3个数,表示与第i个城市相邻的3个城市.第20行以后每行有1个数m,m<=20,m>=1.m=0退出.输出描述:输出从第m个城市出发经过每个城市1次又回到m的所有路线,如有多条路线,按字典序输出,每行1条路线.每行首先输...原创 2019-08-17 19:32:22 · 185 阅读 · 0 评论