A forest has a network of jogging trails. There are N intersections and N−1 trails, and between any two intersections there is exactly one route along the trails, so the whole network forms a tree.
Every jogger starts at intersection 1, runs exactly S meters in total, and finishes back at intersection 1. A jogger can turn around at any point, including the middle of a trail, and can turn around as many times as she wants. Nobody knows which route a jogger takes, so treat every route that meets those conditions as one that might really be run. Running over part of a trail and turning back still counts as using that trail.
The forest is dark at night. The joggers want every trail they might use to be lit. A trail is lit when at least one of its two end intersections has a lamp. L intersections already have a lamp, and those lamps stay.
Place extra lamps at intersections so that every trail that might be used is lit. Find the smallest number of extra lamps.
The first line has the number of intersections N and the running distance S. (2≤N≤50000, 1≤S≤104)
Each of the next N−1 lines has three integers a, b, d, meaning a bidirectional trail of length d meters joins intersections a and b. (1≤a,b≤N, 1≤d≤100)
The next line has L, the number of intersections that already have a lamp. (0≤L≤N)
The line after that has the L intersection numbers that have a lamp, separated by spaces. The numbers are all different. When L is 0 the line is empty.
Print the smallest number of extra lamps on one line.