import java.util.Scanner;


public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();	//?????????????????°?????????
		String[] mark = {"S","H","C","D"};	//?????????????????????S H C D
		String markTmp;
		int num;		//??????????????°???1~13
		boolean[][] trump = new boolean[4][13];
		
		for (int i = 0; i < n; i++) {
				markTmp=sc.next();
				num=sc.nextInt();
				
				//?????£??????????????????????????§??????
				if(markTmp.equals("S")){
					trump[0][num-1]=true;
				}
				else if (markTmp.equals("H")) {
					trump[1][num-1]=true;
				}
				else if (markTmp.equals("C")) {
					trump[2][num-1]=true;
				}
				else if (markTmp.equals("D")) {
					trump[3][num-1]=true;
				}
		}
		
		//?????£??????????????????????????????
		for (int i = 0; i < trump.length; i++) {
			for (int j = 0; j < trump[i].length; j++) {
				if(trump[i][j] == false){
					System.out.println(mark[i]+" "+(j+1));
				}
			}
			
		}
	}
} import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();	//?????????????????°?????????
		String[] mark = {"S","H","C","D"};	//?????????????????????S H C D
		String markTmp;
		int num;		//??????????????°???1~13
		boolean[][] trump = new boolean[4][13];
		
		for (int i = 0; i < n; i++) {
				markTmp=sc.next();
				num=sc.nextInt();
				
				//?????£??????????????????????????§??????
				if(markTmp.equals("S")){
					trump[0][num-1]=true;
				}
				else if (markTmp.equals("H")) {
					trump[1][num-1]=true;
				}
				else if (markTmp.equals("C")) {
					trump[2][num-1]=true;
				}
				else if (markTmp.equals("D")) {
					trump[3][num-1]=true;
				}
		}
		
		//?????£??????????????????????????????
		for (int i = 0; i < trump.length; i++) {
			for (int j = 0; j < trump[i].length; j++) {
				if(trump[i][j] == false){
					System.out.println(mark[i]+" "+(j+1));
				}
			}
			
		}
	}
} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();	//?????????????????°?????????
		String[] mark = {"S","H","C","D"};	//?????????????????????S H C D
		String markTmp;
		int num;		//??????????????°???1~13
		boolean[][] trump = new boolean[4][13];
		
		for (int i = 0; i < n; i++) {
				markTmp=sc.next();
				num=sc.nextInt();
				
				//?????£??????????????????????????§??????
				if(markTmp.equals("S")){
					trump[0][num-1]=true;
				}
				else if (markTmp.equals("H")) {
					trump[1][num-1]=true;
				}
				else if (markTmp.equals("C")) {
					trump[2][num-1]=true;
				}
				else if (markTmp.equals("D")) {
					trump[3][num-1]=true;
				}
		}
		
		//?????£??????????????????????????????
		for (int i = 0; i < trump.length; i++) {
			for (int j = 0; j < trump[i].length; j++) {
				if(trump[i][j] == false){
					System.out.println(mark[i]+" "+(j+1));
				}
			}
			
		}
	} main {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();	//?????????????????°?????????
		String[] mark = {"S","H","C","D"};	//?????????????????????S H C D
		String markTmp;
		int num;		//??????????????°???1~13
		boolean[][] trump = new boolean[4][13];
		
		for (int i = 0; i < n; i++) {
				markTmp=sc.next();
				num=sc.nextInt();
				
				//?????£??????????????????????????§??????
				if(markTmp.equals("S")){
					trump[0][num-1]=true;
				}
				else if (markTmp.equals("H")) {
					trump[1][num-1]=true;
				}
				else if (markTmp.equals("C")) {
					trump[2][num-1]=true;
				}
				else if (markTmp.equals("D")) {
					trump[3][num-1]=true;
				}
		}
		
		//?????£??????????????????????????????
		for (int i = 0; i < trump.length; i++) {
			for (int j = 0; j < trump[i].length; j++) {
				if(trump[i][j] == false){
					System.out.println(mark[i]+" "+(j+1));
				}
			}
			
		}
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc String[] mark = {"S","H","C","D"}; mark {"S","H","C","D"} "S" "H" "C" "D" String markTmp; markTmp int num; num boolean[][] trump = new boolean[4][13]; trump new boolean[4][13] 4 13 for (int i = 0; i < n; i++) {
				markTmp=sc.next();
				num=sc.nextInt();
				
				//?????£??????????????????????????§??????
				if(markTmp.equals("S")){
					trump[0][num-1]=true;
				}
				else if (markTmp.equals("H")) {
					trump[1][num-1]=true;
				}
				else if (markTmp.equals("C")) {
					trump[2][num-1]=true;
				}
				else if (markTmp.equals("D")) {
					trump[3][num-1]=true;
				}
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
				markTmp=sc.next();
				num=sc.nextInt();
				
				//?????£??????????????????????????§??????
				if(markTmp.equals("S")){
					trump[0][num-1]=true;
				}
				else if (markTmp.equals("H")) {
					trump[1][num-1]=true;
				}
				else if (markTmp.equals("C")) {
					trump[2][num-1]=true;
				}
				else if (markTmp.equals("D")) {
					trump[3][num-1]=true;
				}
		} {
				markTmp=sc.next();
				num=sc.nextInt();
				
				//?????£??????????????????????????§??????
				if(markTmp.equals("S")){
					trump[0][num-1]=true;
				}
				else if (markTmp.equals("H")) {
					trump[1][num-1]=true;
				}
				else if (markTmp.equals("C")) {
					trump[2][num-1]=true;
				}
				else if (markTmp.equals("D")) {
					trump[3][num-1]=true;
				}
		} markTmp=sc.next() markTmp sc.next() sc.next sc num=sc.nextInt() num sc.nextInt() sc.nextInt sc if(markTmp.equals("S")){
					trump[0][num-1]=true;
				}
				else if (markTmp.equals("H")) {
					trump[1][num-1]=true;
				}
				else if (markTmp.equals("C")) {
					trump[2][num-1]=true;
				}
				else if (markTmp.equals("D")) {
					trump[3][num-1]=true;
				} markTmp.equals("S") markTmp.equals markTmp "S" {
					trump[0][num-1]=true;
				} trump[0][num-1]=true trump[0][num-1] trump[0] trump 0 num-1 num 1 true if (markTmp.equals("H")) {
					trump[1][num-1]=true;
				}
				else if (markTmp.equals("C")) {
					trump[2][num-1]=true;
				}
				else if (markTmp.equals("D")) {
					trump[3][num-1]=true;
				} markTmp.equals("H") markTmp.equals markTmp "H" {
					trump[1][num-1]=true;
				} trump[1][num-1]=true trump[1][num-1] trump[1] trump 1 num-1 num 1 true if (markTmp.equals("C")) {
					trump[2][num-1]=true;
				}
				else if (markTmp.equals("D")) {
					trump[3][num-1]=true;
				} markTmp.equals("C") markTmp.equals markTmp "C" {
					trump[2][num-1]=true;
				} trump[2][num-1]=true trump[2][num-1] trump[2] trump 2 num-1 num 1 true if (markTmp.equals("D")) {
					trump[3][num-1]=true;
				} markTmp.equals("D") markTmp.equals markTmp "D" {
					trump[3][num-1]=true;
				} trump[3][num-1]=true trump[3][num-1] trump[3] trump 3 num-1 num 1 true for (int i = 0; i < trump.length; i++) {
			for (int j = 0; j < trump[i].length; j++) {
				if(trump[i][j] == false){
					System.out.println(mark[i]+" "+(j+1));
				}
			}
			
		} int i = 0; int i = 0; i 0 i < trump.length i trump.length trump trump.length i++ i++ i {
			for (int j = 0; j < trump[i].length; j++) {
				if(trump[i][j] == false){
					System.out.println(mark[i]+" "+(j+1));
				}
			}
			
		} {
			for (int j = 0; j < trump[i].length; j++) {
				if(trump[i][j] == false){
					System.out.println(mark[i]+" "+(j+1));
				}
			}
			
		} for (int j = 0; j < trump[i].length; j++) {
				if(trump[i][j] == false){
					System.out.println(mark[i]+" "+(j+1));
				}
			} int j = 0; int j = 0; j 0 j < trump[i].length j trump[i].length trump[i] trump i trump[i].length j++ j++ j {
				if(trump[i][j] == false){
					System.out.println(mark[i]+" "+(j+1));
				}
			} {
				if(trump[i][j] == false){
					System.out.println(mark[i]+" "+(j+1));
				}
			} if(trump[i][j] == false){
					System.out.println(mark[i]+" "+(j+1));
				} trump[i][j] == false trump[i][j] trump[i] trump i j false {
					System.out.println(mark[i]+" "+(j+1));
				} System.out.println(mark[i]+" "+(j+1)) System.out.println System.out System System.out mark[i]+" "+(j+1) mark[i]+" "+(j+1) mark[i] mark i " " (j+1) j 1 String[] args args public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();	//?????????????????°?????????
		String[] mark = {"S","H","C","D"};	//?????????????????????S H C D
		String markTmp;
		int num;		//??????????????°???1~13
		boolean[][] trump = new boolean[4][13];
		
		for (int i = 0; i < n; i++) {
				markTmp=sc.next();
				num=sc.nextInt();
				
				//?????£??????????????????????????§??????
				if(markTmp.equals("S")){
					trump[0][num-1]=true;
				}
				else if (markTmp.equals("H")) {
					trump[1][num-1]=true;
				}
				else if (markTmp.equals("C")) {
					trump[2][num-1]=true;
				}
				else if (markTmp.equals("D")) {
					trump[3][num-1]=true;
				}
		}
		
		//?????£??????????????????????????????
		for (int i = 0; i < trump.length; i++) {
			for (int j = 0; j < trump[i].length; j++) {
				if(trump[i][j] == false){
					System.out.println(mark[i]+" "+(j+1));
				}
			}
			
		}
	}
} public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();	//?????????????????°?????????
		String[] mark = {"S","H","C","D"};	//?????????????????????S H C D
		String markTmp;
		int num;		//??????????????°???1~13
		boolean[][] trump = new boolean[4][13];
		
		for (int i = 0; i < n; i++) {
				markTmp=sc.next();
				num=sc.nextInt();
				
				//?????£??????????????????????????§??????
				if(markTmp.equals("S")){
					trump[0][num-1]=true;
				}
				else if (markTmp.equals("H")) {
					trump[1][num-1]=true;
				}
				else if (markTmp.equals("C")) {
					trump[2][num-1]=true;
				}
				else if (markTmp.equals("D")) {
					trump[3][num-1]=true;
				}
		}
		
		//?????£??????????????????????????????
		for (int i = 0; i < trump.length; i++) {
			for (int j = 0; j < trump[i].length; j++) {
				if(trump[i][j] == false){
					System.out.println(mark[i]+" "+(j+1));
				}
			}
			
		}
	}
} Main
import java.util.Scanner;


public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();	//?????????????????°?????????
		String[] mark = {"S","H","C","D"};	//?????????????????????S H C D
		String markTmp;
		int num;		//??????????????°???1~13
		boolean[][] trump = new boolean[4][13];
		
		for (int i = 0; i < n; i++) {
				markTmp=sc.next();
				num=sc.nextInt();
				
				//?????£??????????????????????????§??????
				if(markTmp.equals("S")){
					trump[0][num-1]=true;
				}
				else if (markTmp.equals("H")) {
					trump[1][num-1]=true;
				}
				else if (markTmp.equals("C")) {
					trump[2][num-1]=true;
				}
				else if (markTmp.equals("D")) {
					trump[3][num-1]=true;
				}
		}
		
		//?????£??????????????????????????????
		for (int i = 0; i < trump.length; i++) {
			for (int j = 0; j < trump[i].length; j++) {
				if(trump[i][j] == false){
					System.out.println(mark[i]+" "+(j+1));
				}
			}
			
		}
	}
}