
import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int a = scanner.nextInt();
		int[][] array = new int[4][13];
		for (int i = 0; i < a; i++) {
			String b = scanner.next();
			int c = scanner.nextInt();
			if (b.equals("S"))
				array[0][c - 1] = 1;
			else if (b.equals("H"))
				array[1][c - 1] = 1;
			else if (b.equals("C"))
				array[2][c - 1] = 1;
			else
				array[3][c - 1] = 1;
		}
		for (int i = 0; i < 4; i++) {
			for (int j = 0; j < 13; j++) {
				if (array[i][j] == 0)
					if (i == 0)
						System.out.println("S " + (j + 1));
					else if (i == 1)
						System.out.println("H " + (j + 1));
					else if (i == 2)
						System.out.println("C " + (j + 1));
					else
						System.out.println("D " + (j + 1));
			}
		}
	}
} import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int a = scanner.nextInt();
		int[][] array = new int[4][13];
		for (int i = 0; i < a; i++) {
			String b = scanner.next();
			int c = scanner.nextInt();
			if (b.equals("S"))
				array[0][c - 1] = 1;
			else if (b.equals("H"))
				array[1][c - 1] = 1;
			else if (b.equals("C"))
				array[2][c - 1] = 1;
			else
				array[3][c - 1] = 1;
		}
		for (int i = 0; i < 4; i++) {
			for (int j = 0; j < 13; j++) {
				if (array[i][j] == 0)
					if (i == 0)
						System.out.println("S " + (j + 1));
					else if (i == 1)
						System.out.println("H " + (j + 1));
					else if (i == 2)
						System.out.println("C " + (j + 1));
					else
						System.out.println("D " + (j + 1));
			}
		}
	}
} Main public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int a = scanner.nextInt();
		int[][] array = new int[4][13];
		for (int i = 0; i < a; i++) {
			String b = scanner.next();
			int c = scanner.nextInt();
			if (b.equals("S"))
				array[0][c - 1] = 1;
			else if (b.equals("H"))
				array[1][c - 1] = 1;
			else if (b.equals("C"))
				array[2][c - 1] = 1;
			else
				array[3][c - 1] = 1;
		}
		for (int i = 0; i < 4; i++) {
			for (int j = 0; j < 13; j++) {
				if (array[i][j] == 0)
					if (i == 0)
						System.out.println("S " + (j + 1));
					else if (i == 1)
						System.out.println("H " + (j + 1));
					else if (i == 2)
						System.out.println("C " + (j + 1));
					else
						System.out.println("D " + (j + 1));
			}
		}
	} main {
		Scanner scanner = new Scanner(System.in);
		int a = scanner.nextInt();
		int[][] array = new int[4][13];
		for (int i = 0; i < a; i++) {
			String b = scanner.next();
			int c = scanner.nextInt();
			if (b.equals("S"))
				array[0][c - 1] = 1;
			else if (b.equals("H"))
				array[1][c - 1] = 1;
			else if (b.equals("C"))
				array[2][c - 1] = 1;
			else
				array[3][c - 1] = 1;
		}
		for (int i = 0; i < 4; i++) {
			for (int j = 0; j < 13; j++) {
				if (array[i][j] == 0)
					if (i == 0)
						System.out.println("S " + (j + 1));
					else if (i == 1)
						System.out.println("H " + (j + 1));
					else if (i == 2)
						System.out.println("C " + (j + 1));
					else
						System.out.println("D " + (j + 1));
			}
		}
	} Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) int a = scanner.nextInt(); a scanner.nextInt() scanner.nextInt scanner int[][] array = new int[4][13]; array new int[4][13] 4 13 for (int i = 0; i < a; i++) {
			String b = scanner.next();
			int c = scanner.nextInt();
			if (b.equals("S"))
				array[0][c - 1] = 1;
			else if (b.equals("H"))
				array[1][c - 1] = 1;
			else if (b.equals("C"))
				array[2][c - 1] = 1;
			else
				array[3][c - 1] = 1;
		} int i = 0; int i = 0; i 0 i < a i a i++ i++ i {
			String b = scanner.next();
			int c = scanner.nextInt();
			if (b.equals("S"))
				array[0][c - 1] = 1;
			else if (b.equals("H"))
				array[1][c - 1] = 1;
			else if (b.equals("C"))
				array[2][c - 1] = 1;
			else
				array[3][c - 1] = 1;
		} {
			String b = scanner.next();
			int c = scanner.nextInt();
			if (b.equals("S"))
				array[0][c - 1] = 1;
			else if (b.equals("H"))
				array[1][c - 1] = 1;
			else if (b.equals("C"))
				array[2][c - 1] = 1;
			else
				array[3][c - 1] = 1;
		} String b = scanner.next(); b scanner.next() scanner.next scanner int c = scanner.nextInt(); c scanner.nextInt() scanner.nextInt scanner if (b.equals("S"))
				array[0][c - 1] = 1;
			else if (b.equals("H"))
				array[1][c - 1] = 1;
			else if (b.equals("C"))
				array[2][c - 1] = 1;
			else
				array[3][c - 1] = 1; b.equals("S") b.equals b "S" array[0][c - 1] = 1 array[0][c - 1] array[0] array 0 c - 1 c 1 1 if (b.equals("H"))
				array[1][c - 1] = 1;
			else if (b.equals("C"))
				array[2][c - 1] = 1;
			else
				array[3][c - 1] = 1; b.equals("H") b.equals b "H" array[1][c - 1] = 1 array[1][c - 1] array[1] array 1 c - 1 c 1 1 if (b.equals("C"))
				array[2][c - 1] = 1;
			else
				array[3][c - 1] = 1; b.equals("C") b.equals b "C" array[2][c - 1] = 1 array[2][c - 1] array[2] array 2 c - 1 c 1 1 array[3][c - 1] = 1 array[3][c - 1] array[3] array 3 c - 1 c 1 1 for (int i = 0; i < 4; i++) {
			for (int j = 0; j < 13; j++) {
				if (array[i][j] == 0)
					if (i == 0)
						System.out.println("S " + (j + 1));
					else if (i == 1)
						System.out.println("H " + (j + 1));
					else if (i == 2)
						System.out.println("C " + (j + 1));
					else
						System.out.println("D " + (j + 1));
			}
		} int i = 0; int i = 0; i 0 i < 4 i 4 i++ i++ i {
			for (int j = 0; j < 13; j++) {
				if (array[i][j] == 0)
					if (i == 0)
						System.out.println("S " + (j + 1));
					else if (i == 1)
						System.out.println("H " + (j + 1));
					else if (i == 2)
						System.out.println("C " + (j + 1));
					else
						System.out.println("D " + (j + 1));
			}
		} {
			for (int j = 0; j < 13; j++) {
				if (array[i][j] == 0)
					if (i == 0)
						System.out.println("S " + (j + 1));
					else if (i == 1)
						System.out.println("H " + (j + 1));
					else if (i == 2)
						System.out.println("C " + (j + 1));
					else
						System.out.println("D " + (j + 1));
			}
		} for (int j = 0; j < 13; j++) {
				if (array[i][j] == 0)
					if (i == 0)
						System.out.println("S " + (j + 1));
					else if (i == 1)
						System.out.println("H " + (j + 1));
					else if (i == 2)
						System.out.println("C " + (j + 1));
					else
						System.out.println("D " + (j + 1));
			} int j = 0; int j = 0; j 0 j < 13 j 13 j++ j++ j {
				if (array[i][j] == 0)
					if (i == 0)
						System.out.println("S " + (j + 1));
					else if (i == 1)
						System.out.println("H " + (j + 1));
					else if (i == 2)
						System.out.println("C " + (j + 1));
					else
						System.out.println("D " + (j + 1));
			} {
				if (array[i][j] == 0)
					if (i == 0)
						System.out.println("S " + (j + 1));
					else if (i == 1)
						System.out.println("H " + (j + 1));
					else if (i == 2)
						System.out.println("C " + (j + 1));
					else
						System.out.println("D " + (j + 1));
			} if (array[i][j] == 0)
					if (i == 0)
						System.out.println("S " + (j + 1));
					else if (i == 1)
						System.out.println("H " + (j + 1));
					else if (i == 2)
						System.out.println("C " + (j + 1));
					else
						System.out.println("D " + (j + 1)); array[i][j] == 0 array[i][j] array[i] array i j 0 if (i == 0)
						System.out.println("S " + (j + 1));
					else if (i == 1)
						System.out.println("H " + (j + 1));
					else if (i == 2)
						System.out.println("C " + (j + 1));
					else
						System.out.println("D " + (j + 1)); i == 0 i 0 System.out.println("S " + (j + 1)) System.out.println System.out System System.out "S " + (j + 1) "S " (j + 1) j 1 if (i == 1)
						System.out.println("H " + (j + 1));
					else if (i == 2)
						System.out.println("C " + (j + 1));
					else
						System.out.println("D " + (j + 1)); i == 1 i 1 System.out.println("H " + (j + 1)) System.out.println System.out System System.out "H " + (j + 1) "H " (j + 1) j 1 if (i == 2)
						System.out.println("C " + (j + 1));
					else
						System.out.println("D " + (j + 1)); i == 2 i 2 System.out.println("C " + (j + 1)) System.out.println System.out System System.out "C " + (j + 1) "C " (j + 1) j 1 System.out.println("D " + (j + 1)) System.out.println System.out System System.out "D " + (j + 1) "D " (j + 1) j 1 String[] args args public class Main {
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int a = scanner.nextInt();
		int[][] array = new int[4][13];
		for (int i = 0; i < a; i++) {
			String b = scanner.next();
			int c = scanner.nextInt();
			if (b.equals("S"))
				array[0][c - 1] = 1;
			else if (b.equals("H"))
				array[1][c - 1] = 1;
			else if (b.equals("C"))
				array[2][c - 1] = 1;
			else
				array[3][c - 1] = 1;
		}
		for (int i = 0; i < 4; i++) {
			for (int j = 0; j < 13; j++) {
				if (array[i][j] == 0)
					if (i == 0)
						System.out.println("S " + (j + 1));
					else if (i == 1)
						System.out.println("H " + (j + 1));
					else if (i == 2)
						System.out.println("C " + (j + 1));
					else
						System.out.println("D " + (j + 1));
			}
		}
	}
} public class Main {
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int a = scanner.nextInt();
		int[][] array = new int[4][13];
		for (int i = 0; i < a; i++) {
			String b = scanner.next();
			int c = scanner.nextInt();
			if (b.equals("S"))
				array[0][c - 1] = 1;
			else if (b.equals("H"))
				array[1][c - 1] = 1;
			else if (b.equals("C"))
				array[2][c - 1] = 1;
			else
				array[3][c - 1] = 1;
		}
		for (int i = 0; i < 4; i++) {
			for (int j = 0; j < 13; j++) {
				if (array[i][j] == 0)
					if (i == 0)
						System.out.println("S " + (j + 1));
					else if (i == 1)
						System.out.println("H " + (j + 1));
					else if (i == 2)
						System.out.println("C " + (j + 1));
					else
						System.out.println("D " + (j + 1));
			}
		}
	}
} Main

import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int a = scanner.nextInt();
		int[][] array = new int[4][13];
		for (int i = 0; i < a; i++) {
			String b = scanner.next();
			int c = scanner.nextInt();
			if (b.equals("S"))
				array[0][c - 1] = 1;
			else if (b.equals("H"))
				array[1][c - 1] = 1;
			else if (b.equals("C"))
				array[2][c - 1] = 1;
			else
				array[3][c - 1] = 1;
		}
		for (int i = 0; i < 4; i++) {
			for (int j = 0; j < 13; j++) {
				if (array[i][j] == 0)
					if (i == 0)
						System.out.println("S " + (j + 1));
					else if (i == 1)
						System.out.println("H " + (j + 1));
					else if (i == 2)
						System.out.println("C " + (j + 1));
					else
						System.out.println("D " + (j + 1));
			}
		}
	}
}