(hdu step 6.3.3)Air Raid(最小路径覆盖:求用最少边把所有的顶

Your program should read sets of data. The first line of the input file contains the number of the data sets. Each data set specifies the structure of a town and has the format:no_of_intersectionsno_of_streetsS1 E1S2 E2……Sno_of_streets Eno_of_streetsThe first line of each data set contains a positive integer no_of_intersections (greater than 0 and less or equal to 120), which is the number of intersections in the town. The second line contains a positive integer no_of_streets, which is the number of streets in the town. The next no_of_streets lines, one for each street in the town, are randomly ordered and represent the town’s streets. The line corresponding to street k (k <= no_of_streets) consists of two positive integers, separated by one blank: Sk (1 <= Sk <= no_of_intersections) – the number of the intersection that is the start of the street, and Ek (1 <= Ek <= no_of_intersections) – the number of the intersection that is the end of the street. Intersections are represented by integers from 1 to no_of_intersections.There are no blank lines between consecutive sets of data. Input data are correct.

,那么前世我的目光一定一刻都没从你身上离开过吧!

(hdu step 6.3.3)Air Raid(最小路径覆盖:求用最少边把所有的顶

相关文章:

你感兴趣的文章:

标签云: