链接: http://poj.org/problem?id=1087 http://acm.hust.edu.cn/vjudge/contest/view.action?cid=82835#problem/C http://acm.hust.edu.cn/vjudge/contest/view.action?cid=88230#problem/J(密码:0817) n个插座,m个电器及其对应的插座,k个转化器,前一个插座可以转化为后一个插座,问最少有多少设备没有插座用,转换器数量不限最大流,源点…
You are in charge of setting up the press room for the inaugural meeting of the United Nations Internet eXecutive (UNIX), which has an international mandate to make the free flow of information and ideas on the Internet as cumbersome and bureaucratic…
题目大意:这个题意有些蛋疼,看了很大会才明白什么意思,有N个插座,这些插座都是有类型的只能给这种类型的电器充电,下面接着给了M种电器,和电器的插头类型,还有K种转换器,可以把一种类型转换成另一种,转换器也是可以串联使用的. 输入说明: 首先输入的是一个N,下面有N种插座,每种插座都有一个字符串代表,接着输入一个M,表示有M个电器需要充电,输入的每行有一个电器和它需要的插座类型,然后输入一个K,下面有K个转换器. 分析:这个英文写的这么长确实比较难理解,不过看懂题意后也是比较容易了,可以让电器给可…
题意: 几种插头,每一种都只有一个,但有无限个插头转换器,转换器(a,b) 意味着 可以把b转换为a,有几个设备,每个设备对应一种插头,求所不能匹配插头的设备数量 这个题可以用二分图做 , 我用的是最大流,最后用设备数 减去 最大匹配数即可 #include <iostream> #include <cstring> #include <cstdio> #include <algorithm> #include <cmath> #include…
A Plug for UNIX Time Limit: 1000MS   Memory Limit: 65536K Total Submissions: 15597   Accepted: 5308 Description You are in charge of setting up the press room for the inaugural meeting of the United Nations Internet eXecutive (UNIX), which has an int…
题面 You are in charge of setting up the press room for the inaugural meeting of the United Nations Internet eXecutive (UNIX), which has an international mandate to make the free flow of information and ideas on the Internet as cumbersome and bureaucra…
http://poj.org/problem?id=1087 好久没遇见过这么坑的题了这个题真是挫的够可以的.题目大意:你作为某高管去住宿了,然后宾馆里有几种插座,分别有其对应型号,你携带了几种用电器(手机,电脑一类的), 也有其对应型号:可是不一定用电器就能和插座匹配上,于是宾馆的商店里提供了一些转换器,这些转换器可以将某一型号电源转换成另一型号的.问,你的用电器最少会有多少种无 法充电.也就是问可以用上电的用电器的最大数目,之后用电器总数减去此可用电最大数目即可得到最小不能用电数目. 一开始…
没啥好说的,慢慢建图 Sample Input 4 A B C D 5 laptop B phone C pager B clock B comb X 3 B X X A X D Sample Output 1 题意:有n个不同的插座,有m台不同的机器需要m种插头,有k组转换:插头A能由插头B转换而来.问这些机器最少有几台不能插上插座. #include<cstdio> #include<iostream> #include<algorithm> #include<…
POJ 1087 A Plug for UNIX / HDU 1526 A Plug for UNIX / ZOJ 1157 A Plug for UNIX / UVA 753 A Plug for UNIX / UVAlive 5418 A Plug for UNIX / SCU 1671 A Plug for UNIX (网络流) Description You are in charge of setting up the press room for the inaugural meet…
C - A Plug for UNIXTime Limit: 20 Sec Memory Limit: 256 MB 题目连接 http://acm.hust.edu.cn/vjudge/contest/view.action?cid=88038#problem/C Description You are in charge of setting up the press room for the inaugural meeting of the United Nations Internet…