import java.util.Scanner;
public class Main {
	void find(){
		Scanner s = new Scanner(System.in);
		boolean cards[][] = new boolean[4][13];
		String markList[] = new String[4];
		markList[0] = "S";
		markList[1] = "H";
		markList[2] = "C";
		markList[3] = "D";
		for(int j = 0;j<4;j++){
			for(int i = 0;i<13;i++){
				cards[j][i] = false;
			}
		}
		int cnt = s.nextInt();
		for(int i = 0;i < cnt;i++){
			String mark = s.next();
			int num = s.nextInt();
			switch(mark){
			case "S":
				cards[0][num-1] = true;
				break;
			case "H":
				cards[1][num-1] = true;
				break;
			case "C":
				cards[2][num-1] = true;
				break;
			case "D":
				cards[3][num-1] = true;
				break;
			}
		}
		for(int j = 0;j<4;j++){
			for(int i = 0;i<13;i++){
				if(!cards[j][i]){
					System.out.println(markList[j] + " " + (i+1));
				}
			}
		}
	}
	public static void main(String args[]){
		Main m = new Main();
		m.find();
	}
} import java.util.Scanner; Scanner java.util public class Main {
	void find(){
		Scanner s = new Scanner(System.in);
		boolean cards[][] = new boolean[4][13];
		String markList[] = new String[4];
		markList[0] = "S";
		markList[1] = "H";
		markList[2] = "C";
		markList[3] = "D";
		for(int j = 0;j<4;j++){
			for(int i = 0;i<13;i++){
				cards[j][i] = false;
			}
		}
		int cnt = s.nextInt();
		for(int i = 0;i < cnt;i++){
			String mark = s.next();
			int num = s.nextInt();
			switch(mark){
			case "S":
				cards[0][num-1] = true;
				break;
			case "H":
				cards[1][num-1] = true;
				break;
			case "C":
				cards[2][num-1] = true;
				break;
			case "D":
				cards[3][num-1] = true;
				break;
			}
		}
		for(int j = 0;j<4;j++){
			for(int i = 0;i<13;i++){
				if(!cards[j][i]){
					System.out.println(markList[j] + " " + (i+1));
				}
			}
		}
	}
	public static void main(String args[]){
		Main m = new Main();
		m.find();
	}
} Main void find(){
		Scanner s = new Scanner(System.in);
		boolean cards[][] = new boolean[4][13];
		String markList[] = new String[4];
		markList[0] = "S";
		markList[1] = "H";
		markList[2] = "C";
		markList[3] = "D";
		for(int j = 0;j<4;j++){
			for(int i = 0;i<13;i++){
				cards[j][i] = false;
			}
		}
		int cnt = s.nextInt();
		for(int i = 0;i < cnt;i++){
			String mark = s.next();
			int num = s.nextInt();
			switch(mark){
			case "S":
				cards[0][num-1] = true;
				break;
			case "H":
				cards[1][num-1] = true;
				break;
			case "C":
				cards[2][num-1] = true;
				break;
			case "D":
				cards[3][num-1] = true;
				break;
			}
		}
		for(int j = 0;j<4;j++){
			for(int i = 0;i<13;i++){
				if(!cards[j][i]){
					System.out.println(markList[j] + " " + (i+1));
				}
			}
		}
	} find {
		Scanner s = new Scanner(System.in);
		boolean cards[][] = new boolean[4][13];
		String markList[] = new String[4];
		markList[0] = "S";
		markList[1] = "H";
		markList[2] = "C";
		markList[3] = "D";
		for(int j = 0;j<4;j++){
			for(int i = 0;i<13;i++){
				cards[j][i] = false;
			}
		}
		int cnt = s.nextInt();
		for(int i = 0;i < cnt;i++){
			String mark = s.next();
			int num = s.nextInt();
			switch(mark){
			case "S":
				cards[0][num-1] = true;
				break;
			case "H":
				cards[1][num-1] = true;
				break;
			case "C":
				cards[2][num-1] = true;
				break;
			case "D":
				cards[3][num-1] = true;
				break;
			}
		}
		for(int j = 0;j<4;j++){
			for(int i = 0;i<13;i++){
				if(!cards[j][i]){
					System.out.println(markList[j] + " " + (i+1));
				}
			}
		}
	} Scanner s = new Scanner(System.in); s new Scanner(System.in) boolean cards[][] = new boolean[4][13]; cards new boolean[4][13] 4 13 String markList[] = new String[4]; markList new String[4] 4 markList[0] = "S" markList[0] markList 0 "S" markList[1] = "H" markList[1] markList 1 "H" markList[2] = "C" markList[2] markList 2 "C" markList[3] = "D" markList[3] markList 3 "D" for(int j = 0;j<4;j++){
			for(int i = 0;i<13;i++){
				cards[j][i] = false;
			}
		} int j = 0; int j = 0; j 0 j<4 j 4 j++ j++ j {
			for(int i = 0;i<13;i++){
				cards[j][i] = false;
			}
		} {
			for(int i = 0;i<13;i++){
				cards[j][i] = false;
			}
		} for(int i = 0;i<13;i++){
				cards[j][i] = false;
			} int i = 0; int i = 0; i 0 i<13 i 13 i++ i++ i {
				cards[j][i] = false;
			} {
				cards[j][i] = false;
			} cards[j][i] = false cards[j][i] cards[j] cards j i false int cnt = s.nextInt(); cnt s.nextInt() s.nextInt s for(int i = 0;i < cnt;i++){
			String mark = s.next();
			int num = s.nextInt();
			switch(mark){
			case "S":
				cards[0][num-1] = true;
				break;
			case "H":
				cards[1][num-1] = true;
				break;
			case "C":
				cards[2][num-1] = true;
				break;
			case "D":
				cards[3][num-1] = true;
				break;
			}
		} int i = 0; int i = 0; i 0 i < cnt i cnt i++ i++ i {
			String mark = s.next();
			int num = s.nextInt();
			switch(mark){
			case "S":
				cards[0][num-1] = true;
				break;
			case "H":
				cards[1][num-1] = true;
				break;
			case "C":
				cards[2][num-1] = true;
				break;
			case "D":
				cards[3][num-1] = true;
				break;
			}
		} {
			String mark = s.next();
			int num = s.nextInt();
			switch(mark){
			case "S":
				cards[0][num-1] = true;
				break;
			case "H":
				cards[1][num-1] = true;
				break;
			case "C":
				cards[2][num-1] = true;
				break;
			case "D":
				cards[3][num-1] = true;
				break;
			}
		} String mark = s.next(); mark s.next() s.next s int num = s.nextInt(); num s.nextInt() s.nextInt s switch(mark){
			case "S":
				cards[0][num-1] = true;
				break;
			case "H":
				cards[1][num-1] = true;
				break;
			case "C":
				cards[2][num-1] = true;
				break;
			case "D":
				cards[3][num-1] = true;
				break;
			} mark case "S": "S" case "S": cards[0][num-1] = true cards[0][num-1] cards[0] cards 0 num-1 num 1 true break; case "H": "H" case "H": cards[1][num-1] = true cards[1][num-1] cards[1] cards 1 num-1 num 1 true break; case "C": "C" case "C": cards[2][num-1] = true cards[2][num-1] cards[2] cards 2 num-1 num 1 true break; case "D": "D" case "D": cards[3][num-1] = true cards[3][num-1] cards[3] cards 3 num-1 num 1 true break; for(int j = 0;j<4;j++){
			for(int i = 0;i<13;i++){
				if(!cards[j][i]){
					System.out.println(markList[j] + " " + (i+1));
				}
			}
		} int j = 0; int j = 0; j 0 j<4 j 4 j++ j++ j {
			for(int i = 0;i<13;i++){
				if(!cards[j][i]){
					System.out.println(markList[j] + " " + (i+1));
				}
			}
		} {
			for(int i = 0;i<13;i++){
				if(!cards[j][i]){
					System.out.println(markList[j] + " " + (i+1));
				}
			}
		} for(int i = 0;i<13;i++){
				if(!cards[j][i]){
					System.out.println(markList[j] + " " + (i+1));
				}
			} int i = 0; int i = 0; i 0 i<13 i 13 i++ i++ i {
				if(!cards[j][i]){
					System.out.println(markList[j] + " " + (i+1));
				}
			} {
				if(!cards[j][i]){
					System.out.println(markList[j] + " " + (i+1));
				}
			} if(!cards[j][i]){
					System.out.println(markList[j] + " " + (i+1));
				} !cards[j][i] cards[j][i] cards[j] cards j i {
					System.out.println(markList[j] + " " + (i+1));
				} System.out.println(markList[j] + " " + (i+1)) System.out.println System.out System System.out markList[j] + " " + (i+1) markList[j] + " " + (i+1) markList[j] markList j " " (i+1) i 1 public static void main(String args[]){
		Main m = new Main();
		m.find();
	} main {
		Main m = new Main();
		m.find();
	} Main m = new Main(); m new Main() m.find() m.find m String args[] args public class Main {
	void find(){
		Scanner s = new Scanner(System.in);
		boolean cards[][] = new boolean[4][13];
		String markList[] = new String[4];
		markList[0] = "S";
		markList[1] = "H";
		markList[2] = "C";
		markList[3] = "D";
		for(int j = 0;j<4;j++){
			for(int i = 0;i<13;i++){
				cards[j][i] = false;
			}
		}
		int cnt = s.nextInt();
		for(int i = 0;i < cnt;i++){
			String mark = s.next();
			int num = s.nextInt();
			switch(mark){
			case "S":
				cards[0][num-1] = true;
				break;
			case "H":
				cards[1][num-1] = true;
				break;
			case "C":
				cards[2][num-1] = true;
				break;
			case "D":
				cards[3][num-1] = true;
				break;
			}
		}
		for(int j = 0;j<4;j++){
			for(int i = 0;i<13;i++){
				if(!cards[j][i]){
					System.out.println(markList[j] + " " + (i+1));
				}
			}
		}
	}
	public static void main(String args[]){
		Main m = new Main();
		m.find();
	}
} public class Main {
	void find(){
		Scanner s = new Scanner(System.in);
		boolean cards[][] = new boolean[4][13];
		String markList[] = new String[4];
		markList[0] = "S";
		markList[1] = "H";
		markList[2] = "C";
		markList[3] = "D";
		for(int j = 0;j<4;j++){
			for(int i = 0;i<13;i++){
				cards[j][i] = false;
			}
		}
		int cnt = s.nextInt();
		for(int i = 0;i < cnt;i++){
			String mark = s.next();
			int num = s.nextInt();
			switch(mark){
			case "S":
				cards[0][num-1] = true;
				break;
			case "H":
				cards[1][num-1] = true;
				break;
			case "C":
				cards[2][num-1] = true;
				break;
			case "D":
				cards[3][num-1] = true;
				break;
			}
		}
		for(int j = 0;j<4;j++){
			for(int i = 0;i<13;i++){
				if(!cards[j][i]){
					System.out.println(markList[j] + " " + (i+1));
				}
			}
		}
	}
	public static void main(String args[]){
		Main m = new Main();
		m.find();
	}
} Main
import java.util.Scanner;
public class Main {
	void find(){
		Scanner s = new Scanner(System.in);
		boolean cards[][] = new boolean[4][13];
		String markList[] = new String[4];
		markList[0] = "S";
		markList[1] = "H";
		markList[2] = "C";
		markList[3] = "D";
		for(int j = 0;j<4;j++){
			for(int i = 0;i<13;i++){
				cards[j][i] = false;
			}
		}
		int cnt = s.nextInt();
		for(int i = 0;i < cnt;i++){
			String mark = s.next();
			int num = s.nextInt();
			switch(mark){
			case "S":
				cards[0][num-1] = true;
				break;
			case "H":
				cards[1][num-1] = true;
				break;
			case "C":
				cards[2][num-1] = true;
				break;
			case "D":
				cards[3][num-1] = true;
				break;
			}
		}
		for(int j = 0;j<4;j++){
			for(int i = 0;i<13;i++){
				if(!cards[j][i]){
					System.out.println(markList[j] + " " + (i+1));
				}
			}
		}
	}
	public static void main(String args[]){
		Main m = new Main();
		m.find();
	}
}