P28551 [洛谷] [HNOI2005] Interstellar Trade
提高+
题目描述

Problem Description

Input Format

Output Format

If a feasible plan can be found, the output file output.txt should contain two integers X and Y. X represents the trade volume, and Y represents the net profit, separated by a space. If the interstellar trade cannot be completed, the output file output.txt should contain "Poor Coke!" (without quotes).

Sample Input and Output

Sample Input #1

6 3 10 4
1 2 1 1 1
1 2 2 2 1
1 2 3 9 1
1 1 4 0 1
1 1 5 0 1
1 1 6 1 1

Sample Output #1

6 2

Sample Input #2

6 3 2 4
1 2 1 1 1
1 2 2 2 1
1 2 3 0 1
1 1 4 0 1
1 1 5 0 1
1 1 6 1 1

Sample Output #2

Poor Coke!
输入格式

见题面 Input 部分

输出格式

见题面 Output 部分

样例输入
6 3 10 4 1 2 1 1 1 1 2 2 2 1 1 2 3 9 1 1 1 4 0 1 1 1 5 0 1 1 1 6 1 1
样例输出
6 2