def solve(): n, m, k, s, t = list(map(int, input().split())) s -= 1 t -= 1 s, t = min(s, t), max(s, t) count = [0] * n st_connected = False for _ in range(m): u, v = list(map(int, input().split())) u -= 1 v -= 1 u, v = min(u, v), max(u, v) count[u] += 1 count[v] += 1 if s == u and t == v: st_connected = True if (count[s] == 0 and count[t] == 0) or (count[s] == 1 and count[t] == 1 and st_connected): if k % 2 == 1: print("Yes") else: print("No") else: print("Yes") if __name__ == '__main__': solve()