import java.io.*;
import java.util.Arrays;
import java.util.HashSet;
import java.util.Set;

public class Main {
  public static void main(String[] args) throws IOException {
    BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    
    String[] names = br.readLine().split(" ");
    Set<String> nameSet = new HashSet<String>(Arrays.asList(names));
    System.out.println(nameSet.size() == 2 ? "Yes" : "No");
    
  }
} import java.io.*; io.* java import java.util.Arrays; Arrays java.util import java.util.HashSet; HashSet java.util import java.util.Set; Set java.util public class Main {
  public static void main(String[] args) throws IOException {
    BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    
    String[] names = br.readLine().split(" ");
    Set<String> nameSet = new HashSet<String>(Arrays.asList(names));
    System.out.println(nameSet.size() == 2 ? "Yes" : "No");
    
  }
} Main public static void main(String[] args) throws IOException {
    BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    
    String[] names = br.readLine().split(" ");
    Set<String> nameSet = new HashSet<String>(Arrays.asList(names));
    System.out.println(nameSet.size() == 2 ? "Yes" : "No");
    
  } main {
    BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    
    String[] names = br.readLine().split(" ");
    Set<String> nameSet = new HashSet<String>(Arrays.asList(names));
    System.out.println(nameSet.size() == 2 ? "Yes" : "No");
    
  } BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) String[] names = br.readLine().split(" "); names br.readLine().split(" ") br.readLine().split br.readLine() br.readLine br " " Set<String> nameSet = new HashSet<String>(Arrays.asList(names)); nameSet new HashSet<String>(Arrays.asList(names)) System.out.println(nameSet.size() == 2 ? "Yes" : "No") System.out.println System.out System System.out nameSet.size() == 2 ? "Yes" : "No" nameSet.size() == 2 nameSet.size() nameSet.size nameSet 2 "Yes" "No" String[] args args public class Main {
  public static void main(String[] args) throws IOException {
    BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    
    String[] names = br.readLine().split(" ");
    Set<String> nameSet = new HashSet<String>(Arrays.asList(names));
    System.out.println(nameSet.size() == 2 ? "Yes" : "No");
    
  }
} public class Main {
  public static void main(String[] args) throws IOException {
    BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    
    String[] names = br.readLine().split(" ");
    Set<String> nameSet = new HashSet<String>(Arrays.asList(names));
    System.out.println(nameSet.size() == 2 ? "Yes" : "No");
    
  }
} Main
import java.io.*;
import java.util.Arrays;
import java.util.HashSet;
import java.util.Set;

public class Main {
  public static void main(String[] args) throws IOException {
    BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    
    String[] names = br.readLine().split(" ");
    Set<String> nameSet = new HashSet<String>(Arrays.asList(names));
    System.out.println(nameSet.size() == 2 ? "Yes" : "No");
    
  }
}