class dsu(): n=1 parent_or_size=[-1 for i in range(n)] def __init__(self,N): self.n=N self.parent_or_size=[-1 for i in range(N)] def merge(self,a,b): assert 0<=a0: result2.append(result[i]) return result2 import sys input = lambda: sys.stdin.readline().rstrip() n, m = map(int,input().split()) s, g = map(int,input().split()) uv = [list(map(int,input().split())) for _ in range(m)] input() I = set(map(int,input().split())) U = dsu(n + 1) for u, v in uv: if (u in I) or (v in I): continue else: U.merge(u, v) print('Yes' if U.same(s, g) else 'No')