Farmer John is conducting research for a new milk contract in a new territory. He intends to distribute milk to T (1 <= T <= 25,000) towns conveniently numbered 1..T which are connected by up to R (1 <= R <= 50,000) roads conveniently numbered 1..R and/or P (1 <= P <= 50,000) airplane flights conveniently numbered 1..P.
Either road i or plane i connects town

(1 <=

<= T) to town

(1 <=

<= T) with traversal cost

. For roads, 0 <=

<= 10,000; however, due to the strange finances of the airlines, the cost for planes can be quite negative (-10,000 <=

<= 10,000).
Roads are bidirectional and can be traversed from

to

or

to

for the same cost; the cost of a road must be non-negative.
Planes, however, can only be used in the direction from

to

specified in the input. In fact, if there is a plane from

to

it is guaranteed that there is no way to return from

to

with any sequence of roads and planes due to recent antiterror regulation.
Farmer John is known around the world as the source of the world's finest dairy cows. He has in fact received orders for his cows from every single town. He therefore wants to find the cheapest price for delivery to each town from his distribution center in town S (1 <= S <= T) or to know that it is not possible if this is the case.