import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		boolean card[][] = new boolean[4][13];
		@SuppressWarnings("resource")
		Scanner scan = new Scanner(System.in);
		int n = scan.nextInt();
		for(int i = 0; i < n; i++){
			String suit = scan.next();
			int rank = scan.nextInt() - 1;
			switch(suit){
			case "S":
				card[0][rank] = true;
				break;
			case "H":
				card[1][rank] = true;
				break;
			case "C":
				card[2][rank] = true;
				break;
			case "D":
				card[3][rank] = true;
				break;
			}
		}
		for(int i = 0; i < 4; i++){
			for(int j = 0; j < 13; j++){
				if(!card[i][j]){
					switch(i){
					case 0:
						System.out.println("S " + (j + 1)); //?????£??????????????????j+1??¨?¨????????????¨???????????¨????????±?????????
						break;
					case 1:
						System.out.println("H " + (j + 1));
						break;
					case 2:
						System.out.println("C " + (j + 1));
						break;
					case 3:
						System.out.println("D " + (j + 1));
						break;
					}
				}
			}
		}
		//System.out.println();
	}
} import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args) {
		boolean card[][] = new boolean[4][13];
		@SuppressWarnings("resource")
		Scanner scan = new Scanner(System.in);
		int n = scan.nextInt();
		for(int i = 0; i < n; i++){
			String suit = scan.next();
			int rank = scan.nextInt() - 1;
			switch(suit){
			case "S":
				card[0][rank] = true;
				break;
			case "H":
				card[1][rank] = true;
				break;
			case "C":
				card[2][rank] = true;
				break;
			case "D":
				card[3][rank] = true;
				break;
			}
		}
		for(int i = 0; i < 4; i++){
			for(int j = 0; j < 13; j++){
				if(!card[i][j]){
					switch(i){
					case 0:
						System.out.println("S " + (j + 1)); //?????£??????????????????j+1??¨?¨????????????¨???????????¨????????±?????????
						break;
					case 1:
						System.out.println("H " + (j + 1));
						break;
					case 2:
						System.out.println("C " + (j + 1));
						break;
					case 3:
						System.out.println("D " + (j + 1));
						break;
					}
				}
			}
		}
		//System.out.println();
	}
} Main public static void main(String[] args) {
		boolean card[][] = new boolean[4][13];
		@SuppressWarnings("resource")
		Scanner scan = new Scanner(System.in);
		int n = scan.nextInt();
		for(int i = 0; i < n; i++){
			String suit = scan.next();
			int rank = scan.nextInt() - 1;
			switch(suit){
			case "S":
				card[0][rank] = true;
				break;
			case "H":
				card[1][rank] = true;
				break;
			case "C":
				card[2][rank] = true;
				break;
			case "D":
				card[3][rank] = true;
				break;
			}
		}
		for(int i = 0; i < 4; i++){
			for(int j = 0; j < 13; j++){
				if(!card[i][j]){
					switch(i){
					case 0:
						System.out.println("S " + (j + 1)); //?????£??????????????????j+1??¨?¨????????????¨???????????¨????????±?????????
						break;
					case 1:
						System.out.println("H " + (j + 1));
						break;
					case 2:
						System.out.println("C " + (j + 1));
						break;
					case 3:
						System.out.println("D " + (j + 1));
						break;
					}
				}
			}
		}
		//System.out.println();
	} main {
		boolean card[][] = new boolean[4][13];
		@SuppressWarnings("resource")
		Scanner scan = new Scanner(System.in);
		int n = scan.nextInt();
		for(int i = 0; i < n; i++){
			String suit = scan.next();
			int rank = scan.nextInt() - 1;
			switch(suit){
			case "S":
				card[0][rank] = true;
				break;
			case "H":
				card[1][rank] = true;
				break;
			case "C":
				card[2][rank] = true;
				break;
			case "D":
				card[3][rank] = true;
				break;
			}
		}
		for(int i = 0; i < 4; i++){
			for(int j = 0; j < 13; j++){
				if(!card[i][j]){
					switch(i){
					case 0:
						System.out.println("S " + (j + 1)); //?????£??????????????????j+1??¨?¨????????????¨???????????¨????????±?????????
						break;
					case 1:
						System.out.println("H " + (j + 1));
						break;
					case 2:
						System.out.println("C " + (j + 1));
						break;
					case 3:
						System.out.println("D " + (j + 1));
						break;
					}
				}
			}
		}
		//System.out.println();
	} boolean card[][] = new boolean[4][13]; card new boolean[4][13] 4 13 @SuppressWarnings("resource")
		Scanner scan = new Scanner(System.in); scan new Scanner(System.in) int n = scan.nextInt(); n scan.nextInt() scan.nextInt scan for(int i = 0; i < n; i++){
			String suit = scan.next();
			int rank = scan.nextInt() - 1;
			switch(suit){
			case "S":
				card[0][rank] = true;
				break;
			case "H":
				card[1][rank] = true;
				break;
			case "C":
				card[2][rank] = true;
				break;
			case "D":
				card[3][rank] = true;
				break;
			}
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			String suit = scan.next();
			int rank = scan.nextInt() - 1;
			switch(suit){
			case "S":
				card[0][rank] = true;
				break;
			case "H":
				card[1][rank] = true;
				break;
			case "C":
				card[2][rank] = true;
				break;
			case "D":
				card[3][rank] = true;
				break;
			}
		} {
			String suit = scan.next();
			int rank = scan.nextInt() - 1;
			switch(suit){
			case "S":
				card[0][rank] = true;
				break;
			case "H":
				card[1][rank] = true;
				break;
			case "C":
				card[2][rank] = true;
				break;
			case "D":
				card[3][rank] = true;
				break;
			}
		} String suit = scan.next(); suit scan.next() scan.next scan int rank = scan.nextInt() - 1; rank scan.nextInt() - 1 scan.nextInt() scan.nextInt scan 1 switch(suit){
			case "S":
				card[0][rank] = true;
				break;
			case "H":
				card[1][rank] = true;
				break;
			case "C":
				card[2][rank] = true;
				break;
			case "D":
				card[3][rank] = true;
				break;
			} suit case "S": "S" case "S": card[0][rank] = true card[0][rank] card[0] card 0 rank true break; case "H": "H" case "H": card[1][rank] = true card[1][rank] card[1] card 1 rank true break; case "C": "C" case "C": card[2][rank] = true card[2][rank] card[2] card 2 rank true break; case "D": "D" case "D": card[3][rank] = true card[3][rank] card[3] card 3 rank true break; for(int i = 0; i < 4; i++){
			for(int j = 0; j < 13; j++){
				if(!card[i][j]){
					switch(i){
					case 0:
						System.out.println("S " + (j + 1)); //?????£??????????????????j+1??¨?¨????????????¨???????????¨????????±?????????
						break;
					case 1:
						System.out.println("H " + (j + 1));
						break;
					case 2:
						System.out.println("C " + (j + 1));
						break;
					case 3:
						System.out.println("D " + (j + 1));
						break;
					}
				}
			}
		} int i = 0; int i = 0; i 0 i < 4 i 4 i++ i++ i {
			for(int j = 0; j < 13; j++){
				if(!card[i][j]){
					switch(i){
					case 0:
						System.out.println("S " + (j + 1)); //?????£??????????????????j+1??¨?¨????????????¨???????????¨????????±?????????
						break;
					case 1:
						System.out.println("H " + (j + 1));
						break;
					case 2:
						System.out.println("C " + (j + 1));
						break;
					case 3:
						System.out.println("D " + (j + 1));
						break;
					}
				}
			}
		} {
			for(int j = 0; j < 13; j++){
				if(!card[i][j]){
					switch(i){
					case 0:
						System.out.println("S " + (j + 1)); //?????£??????????????????j+1??¨?¨????????????¨???????????¨????????±?????????
						break;
					case 1:
						System.out.println("H " + (j + 1));
						break;
					case 2:
						System.out.println("C " + (j + 1));
						break;
					case 3:
						System.out.println("D " + (j + 1));
						break;
					}
				}
			}
		} for(int j = 0; j < 13; j++){
				if(!card[i][j]){
					switch(i){
					case 0:
						System.out.println("S " + (j + 1)); //?????£??????????????????j+1??¨?¨????????????¨???????????¨????????±?????????
						break;
					case 1:
						System.out.println("H " + (j + 1));
						break;
					case 2:
						System.out.println("C " + (j + 1));
						break;
					case 3:
						System.out.println("D " + (j + 1));
						break;
					}
				}
			} int j = 0; int j = 0; j 0 j < 13 j 13 j++ j++ j {
				if(!card[i][j]){
					switch(i){
					case 0:
						System.out.println("S " + (j + 1)); //?????£??????????????????j+1??¨?¨????????????¨???????????¨????????±?????????
						break;
					case 1:
						System.out.println("H " + (j + 1));
						break;
					case 2:
						System.out.println("C " + (j + 1));
						break;
					case 3:
						System.out.println("D " + (j + 1));
						break;
					}
				}
			} {
				if(!card[i][j]){
					switch(i){
					case 0:
						System.out.println("S " + (j + 1)); //?????£??????????????????j+1??¨?¨????????????¨???????????¨????????±?????????
						break;
					case 1:
						System.out.println("H " + (j + 1));
						break;
					case 2:
						System.out.println("C " + (j + 1));
						break;
					case 3:
						System.out.println("D " + (j + 1));
						break;
					}
				}
			} if(!card[i][j]){
					switch(i){
					case 0:
						System.out.println("S " + (j + 1)); //?????£??????????????????j+1??¨?¨????????????¨???????????¨????????±?????????
						break;
					case 1:
						System.out.println("H " + (j + 1));
						break;
					case 2:
						System.out.println("C " + (j + 1));
						break;
					case 3:
						System.out.println("D " + (j + 1));
						break;
					}
				} !card[i][j] card[i][j] card[i] card i j {
					switch(i){
					case 0:
						System.out.println("S " + (j + 1)); //?????£??????????????????j+1??¨?¨????????????¨???????????¨????????±?????????
						break;
					case 1:
						System.out.println("H " + (j + 1));
						break;
					case 2:
						System.out.println("C " + (j + 1));
						break;
					case 3:
						System.out.println("D " + (j + 1));
						break;
					}
				} switch(i){
					case 0:
						System.out.println("S " + (j + 1)); //?????£??????????????????j+1??¨?¨????????????¨???????????¨????????±?????????
						break;
					case 1:
						System.out.println("H " + (j + 1));
						break;
					case 2:
						System.out.println("C " + (j + 1));
						break;
					case 3:
						System.out.println("D " + (j + 1));
						break;
					} i case 0: 0 case 0: System.out.println("S " + (j + 1)) System.out.println System.out System System.out "S " + (j + 1) "S " (j + 1) j 1 break; case 1: 1 case 1: System.out.println("H " + (j + 1)) System.out.println System.out System System.out "H " + (j + 1) "H " (j + 1) j 1 break; case 2: 2 case 2: System.out.println("C " + (j + 1)) System.out.println System.out System System.out "C " + (j + 1) "C " (j + 1) j 1 break; case 3: 3 case 3: System.out.println("D " + (j + 1)) System.out.println System.out System System.out "D " + (j + 1) "D " (j + 1) j 1 break; String[] args args public class Main {
	public static void main(String[] args) {
		boolean card[][] = new boolean[4][13];
		@SuppressWarnings("resource")
		Scanner scan = new Scanner(System.in);
		int n = scan.nextInt();
		for(int i = 0; i < n; i++){
			String suit = scan.next();
			int rank = scan.nextInt() - 1;
			switch(suit){
			case "S":
				card[0][rank] = true;
				break;
			case "H":
				card[1][rank] = true;
				break;
			case "C":
				card[2][rank] = true;
				break;
			case "D":
				card[3][rank] = true;
				break;
			}
		}
		for(int i = 0; i < 4; i++){
			for(int j = 0; j < 13; j++){
				if(!card[i][j]){
					switch(i){
					case 0:
						System.out.println("S " + (j + 1)); //?????£??????????????????j+1??¨?¨????????????¨???????????¨????????±?????????
						break;
					case 1:
						System.out.println("H " + (j + 1));
						break;
					case 2:
						System.out.println("C " + (j + 1));
						break;
					case 3:
						System.out.println("D " + (j + 1));
						break;
					}
				}
			}
		}
		//System.out.println();
	}
} public class Main {
	public static void main(String[] args) {
		boolean card[][] = new boolean[4][13];
		@SuppressWarnings("resource")
		Scanner scan = new Scanner(System.in);
		int n = scan.nextInt();
		for(int i = 0; i < n; i++){
			String suit = scan.next();
			int rank = scan.nextInt() - 1;
			switch(suit){
			case "S":
				card[0][rank] = true;
				break;
			case "H":
				card[1][rank] = true;
				break;
			case "C":
				card[2][rank] = true;
				break;
			case "D":
				card[3][rank] = true;
				break;
			}
		}
		for(int i = 0; i < 4; i++){
			for(int j = 0; j < 13; j++){
				if(!card[i][j]){
					switch(i){
					case 0:
						System.out.println("S " + (j + 1)); //?????£??????????????????j+1??¨?¨????????????¨???????????¨????????±?????????
						break;
					case 1:
						System.out.println("H " + (j + 1));
						break;
					case 2:
						System.out.println("C " + (j + 1));
						break;
					case 3:
						System.out.println("D " + (j + 1));
						break;
					}
				}
			}
		}
		//System.out.println();
	}
} Main
import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		boolean card[][] = new boolean[4][13];
		@SuppressWarnings("resource")
		Scanner scan = new Scanner(System.in);
		int n = scan.nextInt();
		for(int i = 0; i < n; i++){
			String suit = scan.next();
			int rank = scan.nextInt() - 1;
			switch(suit){
			case "S":
				card[0][rank] = true;
				break;
			case "H":
				card[1][rank] = true;
				break;
			case "C":
				card[2][rank] = true;
				break;
			case "D":
				card[3][rank] = true;
				break;
			}
		}
		for(int i = 0; i < 4; i++){
			for(int j = 0; j < 13; j++){
				if(!card[i][j]){
					switch(i){
					case 0:
						System.out.println("S " + (j + 1)); //?????£??????????????????j+1??¨?¨????????????¨???????????¨????????±?????????
						break;
					case 1:
						System.out.println("H " + (j + 1));
						break;
					case 2:
						System.out.println("C " + (j + 1));
						break;
					case 3:
						System.out.println("D " + (j + 1));
						break;
					}
				}
			}
		}
		//System.out.println();
	}
}