SP14887 GOODA - Good Travels
Description
\\smallskip
Input Format
First line: 4 integers, $ N $ , $ M $ , $ S $ , and $ E $
Next $ N $ lines: 1 integer, $ f_i $ , for $ i = 1..N $
Next $ M $ lines: 2 integers, $ a_i $ and $ b_i $ , for $ i = 1..M $
Output Format
1 integer, the maximal amount of fun The Team can have on their trip.