10024: 动物园

Memory Limit:512 MB Time Limit:5.000 S
Judge Style:Text Compare Creator:
Submit:1 Solved:0

Description

Sample Input Copy

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

Sample Output Copy

13

HINT

2 2 4 3
1 2
1 3
2 4
--------
2 
 demo3