A decorative fence Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 7221 Accepted: 2723 Description Richard just finished building his new house. Now the only thing the house misses is a cute little wooden fence. He had no idea how to m…
题目链接:http://poj.org/problem?id=1037 Description Richard just finished building his new house. Now the only thing the house misses is a cute little wooden fence. He had no idea how to make a wooden fence, so he decided to order one. Somehow he got his…
转自:http://www.cnblogs.com/kuangbin/archive/2011/11/12/2246407.html [题目大意] 一条公路上有n个旅馆,选出其中k个设置仓库,一个仓库可服务若干个旅馆,一个旅馆只需一个仓库服务.问在哪几个旅馆设置仓库,每个仓库服务哪些旅馆,可使得旅馆到仓库的总距离最小,并求出总距离(长理只要求求最后一步). 链接:点我 [数据范围] 1 <= n <= 200, 1 <= k <= 30, k <= n [解题思想] 1.此题…