![](https://img-blog.csdnimg.cn/20201014180756927.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
树的直径
文章平均质量分 64
楚江枫
不忘初心,方得始终
展开
-
【HDU OJ 4514】湫湫系列故事——设计风景线
湫湫系列故事——设计风景线Problem Description 随着杭州西湖的知名度的进一步提升,园林规划专家湫湫希望设计出一条新的经典观光线路,根据老板马小腾的指示,新的风景线最好能建成环形,如果没有条件建成环形,那就建的越长越好。 现在已经勘探确定了n个位置可以用来建设,在它们之间也勘探确定了m条可以设计的路线以及他们的长度。请问是否能够建成环形的风景线?如果不能,风景线最长能够达原创 2016-08-02 22:10:35 · 489 阅读 · 0 评论 -
【POJ 1985 Cow Marathon】
Cow MarathonDescriptionAfter hearing about the epidemic of obesity in the USA, Farmer John wants his cows to get more exercise, so he has committed to create a bovine marathon for his cows to run. The原创 2016-08-02 22:19:02 · 426 阅读 · 0 评论 -
【POJ 1383 】Labyrinth
LabyrinthDescriptionThe northern part of the Pyramid contains a very large and complicated labyrinth. The labyrinth is divided into square blocks, each of them either filled by rock, or free. There is原创 2016-08-02 22:24:20 · 387 阅读 · 0 评论 -
【POJ 2631 Roads in the North】
Roads in the NorthDescriptionBuilding and maintaining roads among communities in the far North is an expensive business. With this in mind, the roads are build such that there is only one route from a原创 2016-08-02 22:28:17 · 353 阅读 · 0 评论 -
【Light oj 1094 Farthest Nodes in a Tree】
Farthest Nodes in a TreeDescription Given a tree (a connected graph with no cycles), you have to find the farthest nodes in the tree. The edges of the tree are weighted and undirected. That means you原创 2016-08-02 22:32:19 · 512 阅读 · 0 评论 -
【POJ 1383 Labyrinth】
LabyrinthDescriptionThe northern part of the Pyramid contains a very large and complicated labyrinth. The labyrinth is divided into square blocks, each of them either filled by rock, or free. There is原创 2016-08-24 21:45:28 · 406 阅读 · 0 评论 -
【HDU 2196 】+ 直径 + 权值更新
Problem Description A 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 connected to one of原创 2016-10-02 22:16:54 · 532 阅读 · 0 评论