题目名称 | 1013. [POJ1017] 装箱问题 |
---|---|
输入输出 | packets.in/out |
难度等级 | ★ |
时间限制 | 1000 ms (1 s) |
内存限制 | 9 MiB |
测试数据 | 1 |
题目来源 | 王者自由 于2012-08-15加入 |
开放分组 | 全部用户 |
提交状态 | |
分类标签 | |
分享题解 |
通过:26, 提交:53, 通过率:49.06% | ||||
布洛尼亚 | 100 | 0.000 s | 0.00 MiB | C++ |
小刘同学 | 100 | 0.000 s | 0.00 MiB | C++ |
乌龙猹 | 100 | 0.000 s | 0.29 MiB | C++ |
· | 100 | 0.000 s | 0.29 MiB | C++ |
_Itachi | 100 | 0.000 s | 0.29 MiB | C++ |
江羽道 | 100 | 0.000 s | 0.29 MiB | C |
YGOI_真神名曰驴蛋蛋 | 100 | 0.000 s | 0.29 MiB | C++ |
奶猹 | 100 | 0.001 s | 0.29 MiB | C++ |
沉迷学习的假的Keller | 100 | 0.001 s | 0.29 MiB | C++ |
svideo | 100 | 0.001 s | 0.29 MiB | C++ |
关于 装箱问题 的近10条评论(全部评论) | ||||
---|---|---|---|---|
回复 @奶猹 :
一起好好抄代码吧!
YGOI_真神名曰驴蛋蛋
2016-11-10 19:03
4楼
| ||||
@phoenix@猹比@ICE LUGER
你们就不能不打表么,不要欺负这种只有一组数据的题了。。。 | ||||
shu
·
2014-11-04 15:53
2楼
| ||||
表示在poj上跪了4次。。
奶猹
2014-10-24 16:42
1楼
|
A factory produces products packed in square packets of the same height h and of the sizes 1*1, 2*2, 3*3, 4*4, 5*5, 6*6. These products are always delivered to customers in the square parcels of the same height h as the products have and of the size 6*6. Because of the expenses it is the interest of the factory as well as of the customer to minimize the number of parcels necessary to deliver the ordered products from the factory to the customer. A good program solving the problem of finding the minimal number of parcels necessary to deliver the given products according to an order would save a lot of money. You are asked to make such a program.
一个工厂生产了一些一样高h,且长*宽是1*1或2*2或3*3或4*4或5*5或6*6规格的产品。这些产品通常用高为h(和产品一样),且长*宽是6*6的包裹打包起来邮给顾客。由于工厂包邮的所以说他们希望邮费尽可能少,顾客也希望拿包裹更加方便,因此他们共同希望包裹的数目尽可能少。给你每种规格产品的数目,写一个程序求装下这些产品需要的最小包裹数。
The input file consists of several lines specifying orders. Each line specifies one order. Orders are described by six integers separated by one space representing successively the number of packets of individual size from the smallest size 1*1 to the biggest size 6*6. The end of the input file is indicated by the line containing six zeros.
输入文件包括多组数据,每组数据一行,每行由六个由空格分开的整数组成,分别描述六种规格(顺序为从1*1到6*6)产品的数目。文件由'0 0 0 0 0 0'结尾。(共计N行)
The output file contains one line for each line in the input file. This line contains the minimal number of parcels into which the order from the corresponding line of the input file can be packed. There is no line in the output file corresponding to the last ``null'' line of the input file.
对于输出文件,每组数据输出一行,每行一个整数,表示装下对应输入文件中的产品所需要的最小包裹数。(输入文件中的'0 0 0 0 0 0'应被忽略,则输出文件共计N-1行)
0 0 4 0 0 1 7 5 1 0 0 0 0 0 0 0 0 0
2 1
POJ 1017
译byKZFFFFFFFF