The first line of input contains four integers,
,
, and
, satisfying
,
,
and
. The value
represents the number of intersections in the city,
represents the number of roads in the city,
is the number of repair stations and
is the distance that you can bike (starting with a fully inflated tire) before your tire goes flat again. The intersections are numbered from
to
. Your school is at intersection
and your home is at intersection
.
The second line of input containsintegers, with values between
and
, inclusive. These are the intersections where the repair stations are located (excluding your school's repair station). All integers on this line are unique.
The next
lines represent the roads in your town. Each has three integers
, where
, and
. These three integers represent that there is a direct road from intersection
to intersection
of length
. Roads can be traveled in either direction. There is at most one road between any two intersections.
Print the minimum total distance you need to travel to reach home from school without getting stuck due to a flat tire. If the trip is not possible, output the word stuck on a single line instead.It is guaranteed that if the trip is possible, the minimum distance
satisfies
.
In the first sample input, if your tire did not have a leak then the shortest path home would have a distance of, going from the school through intersections
and
. However, due to the leak, you can only travel a distance of
before you need to refill the tire, requiring you to use the repair stations at intersections
and
, for a total distance of
.
In the second sample input, if your tire did not have a leak, then the shortest path home would have a distance of. But since your tire only lasts for a distance of
, there's no path where your bike tire will not go flat somewhere along the way. Even when using repair station at intersection
, you get stuck before you can reach either your home or the repair station at intersection
.