import java.util.Arrays;
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {

		//?????£?????????
		int numN;
		String[] InputList = new String[2];
		String[][] Card = new String[4][13];
		String[] NumList;

		Scanner sc = null;

		//?????§????????¨??????????????????
		for (int i = 0; i < Card[0].length; i++) {
				Card[0][i] = "S" + (i + 1);
		}
		for (int i = 0; i < Card[0].length; i++) {
			Card[1][i] = "H" + (i + 1);
		}
		for (int i = 0; i < Card[0].length; i++) {
			Card[2][i] = "C" + (i + 1);
		}
		for (int i = 0; i < Card[0].length; i++) {
			Card[3][i] = "D" + (i + 1);
		}

		try {
			//??\????????????
			sc = new Scanner(System.in);
			numN = sc.nextInt();
			NumList = new String[numN];

			for (int i = 0; i < numN; i++) {

				for (int j = 0; j < InputList.length; j++) {
				//????????????????????????
					String s = sc.next();
					InputList[j] = s;
				}

				//???????????£??\
				NumList[i] = InputList[0] + InputList[1];
			}
			//?????¨??????????????§??????
			for (int i = 0; i < Card.length; i++) {
				for (int j = 0; j < Card[i].length; j++) {
					if(!Arrays.asList(NumList).contains(Card[i][j])){
						System.out.println(Card[i][j].substring(0, 1) + " " + Card[i][j].substring(1));
					}
				}
			}
			//System.out.println(Type);

		} finally {
			sc.close();
		}
	}

} import java.util.Arrays; Arrays java.util import java.util.Scanner; Scanner java.util public class Main {

	public static void main(String[] args) {

		//?????£?????????
		int numN;
		String[] InputList = new String[2];
		String[][] Card = new String[4][13];
		String[] NumList;

		Scanner sc = null;

		//?????§????????¨??????????????????
		for (int i = 0; i < Card[0].length; i++) {
				Card[0][i] = "S" + (i + 1);
		}
		for (int i = 0; i < Card[0].length; i++) {
			Card[1][i] = "H" + (i + 1);
		}
		for (int i = 0; i < Card[0].length; i++) {
			Card[2][i] = "C" + (i + 1);
		}
		for (int i = 0; i < Card[0].length; i++) {
			Card[3][i] = "D" + (i + 1);
		}

		try {
			//??\????????????
			sc = new Scanner(System.in);
			numN = sc.nextInt();
			NumList = new String[numN];

			for (int i = 0; i < numN; i++) {

				for (int j = 0; j < InputList.length; j++) {
				//????????????????????????
					String s = sc.next();
					InputList[j] = s;
				}

				//???????????£??\
				NumList[i] = InputList[0] + InputList[1];
			}
			//?????¨??????????????§??????
			for (int i = 0; i < Card.length; i++) {
				for (int j = 0; j < Card[i].length; j++) {
					if(!Arrays.asList(NumList).contains(Card[i][j])){
						System.out.println(Card[i][j].substring(0, 1) + " " + Card[i][j].substring(1));
					}
				}
			}
			//System.out.println(Type);

		} finally {
			sc.close();
		}
	}

} Main public static void main(String[] args) {

		//?????£?????????
		int numN;
		String[] InputList = new String[2];
		String[][] Card = new String[4][13];
		String[] NumList;

		Scanner sc = null;

		//?????§????????¨??????????????????
		for (int i = 0; i < Card[0].length; i++) {
				Card[0][i] = "S" + (i + 1);
		}
		for (int i = 0; i < Card[0].length; i++) {
			Card[1][i] = "H" + (i + 1);
		}
		for (int i = 0; i < Card[0].length; i++) {
			Card[2][i] = "C" + (i + 1);
		}
		for (int i = 0; i < Card[0].length; i++) {
			Card[3][i] = "D" + (i + 1);
		}

		try {
			//??\????????????
			sc = new Scanner(System.in);
			numN = sc.nextInt();
			NumList = new String[numN];

			for (int i = 0; i < numN; i++) {

				for (int j = 0; j < InputList.length; j++) {
				//????????????????????????
					String s = sc.next();
					InputList[j] = s;
				}

				//???????????£??\
				NumList[i] = InputList[0] + InputList[1];
			}
			//?????¨??????????????§??????
			for (int i = 0; i < Card.length; i++) {
				for (int j = 0; j < Card[i].length; j++) {
					if(!Arrays.asList(NumList).contains(Card[i][j])){
						System.out.println(Card[i][j].substring(0, 1) + " " + Card[i][j].substring(1));
					}
				}
			}
			//System.out.println(Type);

		} finally {
			sc.close();
		}
	} main {

		//?????£?????????
		int numN;
		String[] InputList = new String[2];
		String[][] Card = new String[4][13];
		String[] NumList;

		Scanner sc = null;

		//?????§????????¨??????????????????
		for (int i = 0; i < Card[0].length; i++) {
				Card[0][i] = "S" + (i + 1);
		}
		for (int i = 0; i < Card[0].length; i++) {
			Card[1][i] = "H" + (i + 1);
		}
		for (int i = 0; i < Card[0].length; i++) {
			Card[2][i] = "C" + (i + 1);
		}
		for (int i = 0; i < Card[0].length; i++) {
			Card[3][i] = "D" + (i + 1);
		}

		try {
			//??\????????????
			sc = new Scanner(System.in);
			numN = sc.nextInt();
			NumList = new String[numN];

			for (int i = 0; i < numN; i++) {

				for (int j = 0; j < InputList.length; j++) {
				//????????????????????????
					String s = sc.next();
					InputList[j] = s;
				}

				//???????????£??\
				NumList[i] = InputList[0] + InputList[1];
			}
			//?????¨??????????????§??????
			for (int i = 0; i < Card.length; i++) {
				for (int j = 0; j < Card[i].length; j++) {
					if(!Arrays.asList(NumList).contains(Card[i][j])){
						System.out.println(Card[i][j].substring(0, 1) + " " + Card[i][j].substring(1));
					}
				}
			}
			//System.out.println(Type);

		} finally {
			sc.close();
		}
	} int numN; numN String[] InputList = new String[2]; InputList new String[2] 2 String[][] Card = new String[4][13]; Card new String[4][13] 4 13 String[] NumList; NumList Scanner sc = null; sc null for (int i = 0; i < Card[0].length; i++) {
				Card[0][i] = "S" + (i + 1);
		} int i = 0; int i = 0; i 0 i < Card[0].length i Card[0].length Card[0] Card 0 Card[0].length i++ i++ i {
				Card[0][i] = "S" + (i + 1);
		} {
				Card[0][i] = "S" + (i + 1);
		} Card[0][i] = "S" + (i + 1) Card[0][i] Card[0] Card 0 i "S" + (i + 1) "S" (i + 1) i 1 for (int i = 0; i < Card[0].length; i++) {
			Card[1][i] = "H" + (i + 1);
		} int i = 0; int i = 0; i 0 i < Card[0].length i Card[0].length Card[0] Card 0 Card[0].length i++ i++ i {
			Card[1][i] = "H" + (i + 1);
		} {
			Card[1][i] = "H" + (i + 1);
		} Card[1][i] = "H" + (i + 1) Card[1][i] Card[1] Card 1 i "H" + (i + 1) "H" (i + 1) i 1 for (int i = 0; i < Card[0].length; i++) {
			Card[2][i] = "C" + (i + 1);
		} int i = 0; int i = 0; i 0 i < Card[0].length i Card[0].length Card[0] Card 0 Card[0].length i++ i++ i {
			Card[2][i] = "C" + (i + 1);
		} {
			Card[2][i] = "C" + (i + 1);
		} Card[2][i] = "C" + (i + 1) Card[2][i] Card[2] Card 2 i "C" + (i + 1) "C" (i + 1) i 1 for (int i = 0; i < Card[0].length; i++) {
			Card[3][i] = "D" + (i + 1);
		} int i = 0; int i = 0; i 0 i < Card[0].length i Card[0].length Card[0] Card 0 Card[0].length i++ i++ i {
			Card[3][i] = "D" + (i + 1);
		} {
			Card[3][i] = "D" + (i + 1);
		} Card[3][i] = "D" + (i + 1) Card[3][i] Card[3] Card 3 i "D" + (i + 1) "D" (i + 1) i 1 try {
			//??\????????????
			sc = new Scanner(System.in);
			numN = sc.nextInt();
			NumList = new String[numN];

			for (int i = 0; i < numN; i++) {

				for (int j = 0; j < InputList.length; j++) {
				//????????????????????????
					String s = sc.next();
					InputList[j] = s;
				}

				//???????????£??\
				NumList[i] = InputList[0] + InputList[1];
			}
			//?????¨??????????????§??????
			for (int i = 0; i < Card.length; i++) {
				for (int j = 0; j < Card[i].length; j++) {
					if(!Arrays.asList(NumList).contains(Card[i][j])){
						System.out.println(Card[i][j].substring(0, 1) + " " + Card[i][j].substring(1));
					}
				}
			}
			//System.out.println(Type);

		} finally {
			sc.close();
		} {
			sc.close();
		} sc.close() sc.close sc {
			//??\????????????
			sc = new Scanner(System.in);
			numN = sc.nextInt();
			NumList = new String[numN];

			for (int i = 0; i < numN; i++) {

				for (int j = 0; j < InputList.length; j++) {
				//????????????????????????
					String s = sc.next();
					InputList[j] = s;
				}

				//???????????£??\
				NumList[i] = InputList[0] + InputList[1];
			}
			//?????¨??????????????§??????
			for (int i = 0; i < Card.length; i++) {
				for (int j = 0; j < Card[i].length; j++) {
					if(!Arrays.asList(NumList).contains(Card[i][j])){
						System.out.println(Card[i][j].substring(0, 1) + " " + Card[i][j].substring(1));
					}
				}
			}
			//System.out.println(Type);

		} sc = new Scanner(System.in) sc new Scanner(System.in) numN = sc.nextInt() numN sc.nextInt() sc.nextInt sc NumList = new String[numN] NumList new String[numN] numN for (int i = 0; i < numN; i++) {

				for (int j = 0; j < InputList.length; j++) {
				//????????????????????????
					String s = sc.next();
					InputList[j] = s;
				}

				//???????????£??\
				NumList[i] = InputList[0] + InputList[1];
			} int i = 0; int i = 0; i 0 i < numN i numN i++ i++ i {

				for (int j = 0; j < InputList.length; j++) {
				//????????????????????????
					String s = sc.next();
					InputList[j] = s;
				}

				//???????????£??\
				NumList[i] = InputList[0] + InputList[1];
			} {

				for (int j = 0; j < InputList.length; j++) {
				//????????????????????????
					String s = sc.next();
					InputList[j] = s;
				}

				//???????????£??\
				NumList[i] = InputList[0] + InputList[1];
			} for (int j = 0; j < InputList.length; j++) {
				//????????????????????????
					String s = sc.next();
					InputList[j] = s;
				} int j = 0; int j = 0; j 0 j < InputList.length j InputList.length InputList InputList.length j++ j++ j {
				//????????????????????????
					String s = sc.next();
					InputList[j] = s;
				} {
				//????????????????????????
					String s = sc.next();
					InputList[j] = s;
				} String s = sc.next(); s sc.next() sc.next sc InputList[j] = s InputList[j] InputList j s NumList[i] = InputList[0] + InputList[1] NumList[i] NumList i InputList[0] + InputList[1] InputList[0] InputList 0 InputList[1] InputList 1 for (int i = 0; i < Card.length; i++) {
				for (int j = 0; j < Card[i].length; j++) {
					if(!Arrays.asList(NumList).contains(Card[i][j])){
						System.out.println(Card[i][j].substring(0, 1) + " " + Card[i][j].substring(1));
					}
				}
			} int i = 0; int i = 0; i 0 i < Card.length i Card.length Card Card.length i++ i++ i {
				for (int j = 0; j < Card[i].length; j++) {
					if(!Arrays.asList(NumList).contains(Card[i][j])){
						System.out.println(Card[i][j].substring(0, 1) + " " + Card[i][j].substring(1));
					}
				}
			} {
				for (int j = 0; j < Card[i].length; j++) {
					if(!Arrays.asList(NumList).contains(Card[i][j])){
						System.out.println(Card[i][j].substring(0, 1) + " " + Card[i][j].substring(1));
					}
				}
			} for (int j = 0; j < Card[i].length; j++) {
					if(!Arrays.asList(NumList).contains(Card[i][j])){
						System.out.println(Card[i][j].substring(0, 1) + " " + Card[i][j].substring(1));
					}
				} int j = 0; int j = 0; j 0 j < Card[i].length j Card[i].length Card[i] Card i Card[i].length j++ j++ j {
					if(!Arrays.asList(NumList).contains(Card[i][j])){
						System.out.println(Card[i][j].substring(0, 1) + " " + Card[i][j].substring(1));
					}
				} {
					if(!Arrays.asList(NumList).contains(Card[i][j])){
						System.out.println(Card[i][j].substring(0, 1) + " " + Card[i][j].substring(1));
					}
				} if(!Arrays.asList(NumList).contains(Card[i][j])){
						System.out.println(Card[i][j].substring(0, 1) + " " + Card[i][j].substring(1));
					} !Arrays.asList(NumList).contains(Card[i][j]) Arrays.asList(NumList).contains(Card[i][j]) Arrays.asList(NumList).contains Arrays.asList(NumList) Arrays.asList Arrays NumList Card[i][j] Card[i] Card i j {
						System.out.println(Card[i][j].substring(0, 1) + " " + Card[i][j].substring(1));
					} System.out.println(Card[i][j].substring(0, 1) + " " + Card[i][j].substring(1)) System.out.println System.out System System.out Card[i][j].substring(0, 1) + " " + Card[i][j].substring(1) Card[i][j].substring(0, 1) + " " + Card[i][j].substring(1) Card[i][j].substring(0, 1) Card[i][j].substring Card[i][j] Card[i] Card i j 0 1 " " Card[i][j].substring(1) Card[i][j].substring Card[i][j] Card[i] Card i j 1 String[] args args public class Main {

	public static void main(String[] args) {

		//?????£?????????
		int numN;
		String[] InputList = new String[2];
		String[][] Card = new String[4][13];
		String[] NumList;

		Scanner sc = null;

		//?????§????????¨??????????????????
		for (int i = 0; i < Card[0].length; i++) {
				Card[0][i] = "S" + (i + 1);
		}
		for (int i = 0; i < Card[0].length; i++) {
			Card[1][i] = "H" + (i + 1);
		}
		for (int i = 0; i < Card[0].length; i++) {
			Card[2][i] = "C" + (i + 1);
		}
		for (int i = 0; i < Card[0].length; i++) {
			Card[3][i] = "D" + (i + 1);
		}

		try {
			//??\????????????
			sc = new Scanner(System.in);
			numN = sc.nextInt();
			NumList = new String[numN];

			for (int i = 0; i < numN; i++) {

				for (int j = 0; j < InputList.length; j++) {
				//????????????????????????
					String s = sc.next();
					InputList[j] = s;
				}

				//???????????£??\
				NumList[i] = InputList[0] + InputList[1];
			}
			//?????¨??????????????§??????
			for (int i = 0; i < Card.length; i++) {
				for (int j = 0; j < Card[i].length; j++) {
					if(!Arrays.asList(NumList).contains(Card[i][j])){
						System.out.println(Card[i][j].substring(0, 1) + " " + Card[i][j].substring(1));
					}
				}
			}
			//System.out.println(Type);

		} finally {
			sc.close();
		}
	}

} public class Main {

	public static void main(String[] args) {

		//?????£?????????
		int numN;
		String[] InputList = new String[2];
		String[][] Card = new String[4][13];
		String[] NumList;

		Scanner sc = null;

		//?????§????????¨??????????????????
		for (int i = 0; i < Card[0].length; i++) {
				Card[0][i] = "S" + (i + 1);
		}
		for (int i = 0; i < Card[0].length; i++) {
			Card[1][i] = "H" + (i + 1);
		}
		for (int i = 0; i < Card[0].length; i++) {
			Card[2][i] = "C" + (i + 1);
		}
		for (int i = 0; i < Card[0].length; i++) {
			Card[3][i] = "D" + (i + 1);
		}

		try {
			//??\????????????
			sc = new Scanner(System.in);
			numN = sc.nextInt();
			NumList = new String[numN];

			for (int i = 0; i < numN; i++) {

				for (int j = 0; j < InputList.length; j++) {
				//????????????????????????
					String s = sc.next();
					InputList[j] = s;
				}

				//???????????£??\
				NumList[i] = InputList[0] + InputList[1];
			}
			//?????¨??????????????§??????
			for (int i = 0; i < Card.length; i++) {
				for (int j = 0; j < Card[i].length; j++) {
					if(!Arrays.asList(NumList).contains(Card[i][j])){
						System.out.println(Card[i][j].substring(0, 1) + " " + Card[i][j].substring(1));
					}
				}
			}
			//System.out.println(Type);

		} finally {
			sc.close();
		}
	}

} Main
import java.util.Arrays;
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {

		//?????£?????????
		int numN;
		String[] InputList = new String[2];
		String[][] Card = new String[4][13];
		String[] NumList;

		Scanner sc = null;

		//?????§????????¨??????????????????
		for (int i = 0; i < Card[0].length; i++) {
				Card[0][i] = "S" + (i + 1);
		}
		for (int i = 0; i < Card[0].length; i++) {
			Card[1][i] = "H" + (i + 1);
		}
		for (int i = 0; i < Card[0].length; i++) {
			Card[2][i] = "C" + (i + 1);
		}
		for (int i = 0; i < Card[0].length; i++) {
			Card[3][i] = "D" + (i + 1);
		}

		try {
			//??\????????????
			sc = new Scanner(System.in);
			numN = sc.nextInt();
			NumList = new String[numN];

			for (int i = 0; i < numN; i++) {

				for (int j = 0; j < InputList.length; j++) {
				//????????????????????????
					String s = sc.next();
					InputList[j] = s;
				}

				//???????????£??\
				NumList[i] = InputList[0] + InputList[1];
			}
			//?????¨??????????????§??????
			for (int i = 0; i < Card.length; i++) {
				for (int j = 0; j < Card[i].length; j++) {
					if(!Arrays.asList(NumList).contains(Card[i][j])){
						System.out.println(Card[i][j].substring(0, 1) + " " + Card[i][j].substring(1));
					}
				}
			}
			//System.out.println(Type);

		} finally {
			sc.close();
		}
	}

}