import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class Main {
	public void maain(){

	}

	public static void main(String[] args) throws IOException {
		// TODO ?????????????????????????????????????????????
		//?????????????¨?????????£?¨?
		boolean[] S = new boolean[13];
		boolean[] H = new boolean[13];
		boolean[] C = new boolean[13];
		boolean[] D = new boolean[13];

		//1???????????\????????¢
		InputStreamReader isr = new InputStreamReader(System.in);
        BufferedReader br = new BufferedReader(isr);

        String[] input = br.readLine().split(" ");
        int n = Integer.parseInt(input[0]);

        //2???????????\????????¢
        for(int set = 0;set < n; set++ ){
        	String[] input2 = br.readLine().split(" ");
        	String mark = input2[0];
        	int num = Integer.parseInt(input2[1]);

        	//?????£?????????????????????true???????????????
        	if(mark.equals("S")){
        		S[num - 1] = true;
        	}else if(mark.equals("H")){
        		H[num - 1] = true;
         	}else if(mark.equals("C")){
        		C[num - 1] = true;
        	}else if(mark.equals("D")){
        		D[num - 1] = true;
      		}
        }

        //?????£?????????????????????????????¢?????¨???????????????
    	for(int set = 0;set < 13; set++){
    		if(S[set] == false){
    			System.out.println("S" + " " + (set + 1));
    		}
    	}
    	for(int set = 0;set < 13; set++){
    		if(H[set] == false){
    			System.out.println("H" + " " + (set + 1));
    		}
    	}
    	for(int set = 0;set < 13; set++){
    		if(C[set] == false){
    			System.out.println("C" + " " + (set + 1));
    		}
    	}
    	for(int set = 0;set < 13; set++){
    		if(D[set] == false){
    			System.out.println("D" + " " + (set + 1));
    		}
    	}
	}
} import java.io.BufferedReader; BufferedReader java.io import java.io.IOException; IOException java.io import java.io.InputStreamReader; InputStreamReader java.io public class Main {
	public void maain(){

	}

	public static void main(String[] args) throws IOException {
		// TODO ?????????????????????????????????????????????
		//?????????????¨?????????£?¨?
		boolean[] S = new boolean[13];
		boolean[] H = new boolean[13];
		boolean[] C = new boolean[13];
		boolean[] D = new boolean[13];

		//1???????????\????????¢
		InputStreamReader isr = new InputStreamReader(System.in);
        BufferedReader br = new BufferedReader(isr);

        String[] input = br.readLine().split(" ");
        int n = Integer.parseInt(input[0]);

        //2???????????\????????¢
        for(int set = 0;set < n; set++ ){
        	String[] input2 = br.readLine().split(" ");
        	String mark = input2[0];
        	int num = Integer.parseInt(input2[1]);

        	//?????£?????????????????????true???????????????
        	if(mark.equals("S")){
        		S[num - 1] = true;
        	}else if(mark.equals("H")){
        		H[num - 1] = true;
         	}else if(mark.equals("C")){
        		C[num - 1] = true;
        	}else if(mark.equals("D")){
        		D[num - 1] = true;
      		}
        }

        //?????£?????????????????????????????¢?????¨???????????????
    	for(int set = 0;set < 13; set++){
    		if(S[set] == false){
    			System.out.println("S" + " " + (set + 1));
    		}
    	}
    	for(int set = 0;set < 13; set++){
    		if(H[set] == false){
    			System.out.println("H" + " " + (set + 1));
    		}
    	}
    	for(int set = 0;set < 13; set++){
    		if(C[set] == false){
    			System.out.println("C" + " " + (set + 1));
    		}
    	}
    	for(int set = 0;set < 13; set++){
    		if(D[set] == false){
    			System.out.println("D" + " " + (set + 1));
    		}
    	}
	}
} Main public void maain(){

	} maain {

	} public static void main(String[] args) throws IOException {
		// TODO ?????????????????????????????????????????????
		//?????????????¨?????????£?¨?
		boolean[] S = new boolean[13];
		boolean[] H = new boolean[13];
		boolean[] C = new boolean[13];
		boolean[] D = new boolean[13];

		//1???????????\????????¢
		InputStreamReader isr = new InputStreamReader(System.in);
        BufferedReader br = new BufferedReader(isr);

        String[] input = br.readLine().split(" ");
        int n = Integer.parseInt(input[0]);

        //2???????????\????????¢
        for(int set = 0;set < n; set++ ){
        	String[] input2 = br.readLine().split(" ");
        	String mark = input2[0];
        	int num = Integer.parseInt(input2[1]);

        	//?????£?????????????????????true???????????????
        	if(mark.equals("S")){
        		S[num - 1] = true;
        	}else if(mark.equals("H")){
        		H[num - 1] = true;
         	}else if(mark.equals("C")){
        		C[num - 1] = true;
        	}else if(mark.equals("D")){
        		D[num - 1] = true;
      		}
        }

        //?????£?????????????????????????????¢?????¨???????????????
    	for(int set = 0;set < 13; set++){
    		if(S[set] == false){
    			System.out.println("S" + " " + (set + 1));
    		}
    	}
    	for(int set = 0;set < 13; set++){
    		if(H[set] == false){
    			System.out.println("H" + " " + (set + 1));
    		}
    	}
    	for(int set = 0;set < 13; set++){
    		if(C[set] == false){
    			System.out.println("C" + " " + (set + 1));
    		}
    	}
    	for(int set = 0;set < 13; set++){
    		if(D[set] == false){
    			System.out.println("D" + " " + (set + 1));
    		}
    	}
	} main {
		// TODO ?????????????????????????????????????????????
		//?????????????¨?????????£?¨?
		boolean[] S = new boolean[13];
		boolean[] H = new boolean[13];
		boolean[] C = new boolean[13];
		boolean[] D = new boolean[13];

		//1???????????\????????¢
		InputStreamReader isr = new InputStreamReader(System.in);
        BufferedReader br = new BufferedReader(isr);

        String[] input = br.readLine().split(" ");
        int n = Integer.parseInt(input[0]);

        //2???????????\????????¢
        for(int set = 0;set < n; set++ ){
        	String[] input2 = br.readLine().split(" ");
        	String mark = input2[0];
        	int num = Integer.parseInt(input2[1]);

        	//?????£?????????????????????true???????????????
        	if(mark.equals("S")){
        		S[num - 1] = true;
        	}else if(mark.equals("H")){
        		H[num - 1] = true;
         	}else if(mark.equals("C")){
        		C[num - 1] = true;
        	}else if(mark.equals("D")){
        		D[num - 1] = true;
      		}
        }

        //?????£?????????????????????????????¢?????¨???????????????
    	for(int set = 0;set < 13; set++){
    		if(S[set] == false){
    			System.out.println("S" + " " + (set + 1));
    		}
    	}
    	for(int set = 0;set < 13; set++){
    		if(H[set] == false){
    			System.out.println("H" + " " + (set + 1));
    		}
    	}
    	for(int set = 0;set < 13; set++){
    		if(C[set] == false){
    			System.out.println("C" + " " + (set + 1));
    		}
    	}
    	for(int set = 0;set < 13; set++){
    		if(D[set] == false){
    			System.out.println("D" + " " + (set + 1));
    		}
    	}
	} boolean[] S = new boolean[13]; S new boolean[13] 13 boolean[] H = new boolean[13]; H new boolean[13] 13 boolean[] C = new boolean[13]; C new boolean[13] 13 boolean[] D = new boolean[13]; D new boolean[13] 13 InputStreamReader isr = new InputStreamReader(System.in); isr new InputStreamReader(System.in) BufferedReader br = new BufferedReader(isr); br new BufferedReader(isr) String[] input = br.readLine().split(" "); input br.readLine().split(" ") br.readLine().split br.readLine() br.readLine br " " int n = Integer.parseInt(input[0]); n Integer.parseInt(input[0]) Integer.parseInt Integer input[0] input 0 for(int set = 0;set < n; set++ ){
        	String[] input2 = br.readLine().split(" ");
        	String mark = input2[0];
        	int num = Integer.parseInt(input2[1]);

        	//?????£?????????????????????true???????????????
        	if(mark.equals("S")){
        		S[num - 1] = true;
        	}else if(mark.equals("H")){
        		H[num - 1] = true;
         	}else if(mark.equals("C")){
        		C[num - 1] = true;
        	}else if(mark.equals("D")){
        		D[num - 1] = true;
      		}
        } int set = 0; int set = 0; set 0 set < n set n set++ set++ set {
        	String[] input2 = br.readLine().split(" ");
        	String mark = input2[0];
        	int num = Integer.parseInt(input2[1]);

        	//?????£?????????????????????true???????????????
        	if(mark.equals("S")){
        		S[num - 1] = true;
        	}else if(mark.equals("H")){
        		H[num - 1] = true;
         	}else if(mark.equals("C")){
        		C[num - 1] = true;
        	}else if(mark.equals("D")){
        		D[num - 1] = true;
      		}
        } {
        	String[] input2 = br.readLine().split(" ");
        	String mark = input2[0];
        	int num = Integer.parseInt(input2[1]);

        	//?????£?????????????????????true???????????????
        	if(mark.equals("S")){
        		S[num - 1] = true;
        	}else if(mark.equals("H")){
        		H[num - 1] = true;
         	}else if(mark.equals("C")){
        		C[num - 1] = true;
        	}else if(mark.equals("D")){
        		D[num - 1] = true;
      		}
        } String[] input2 = br.readLine().split(" "); input2 br.readLine().split(" ") br.readLine().split br.readLine() br.readLine br " " String mark = input2[0]; mark input2[0] input2 0 int num = Integer.parseInt(input2[1]); num Integer.parseInt(input2[1]) Integer.parseInt Integer input2[1] input2 1 if(mark.equals("S")){
        		S[num - 1] = true;
        	}else if(mark.equals("H")){
        		H[num - 1] = true;
         	}else if(mark.equals("C")){
        		C[num - 1] = true;
        	}else if(mark.equals("D")){
        		D[num - 1] = true;
      		} mark.equals("S") mark.equals mark "S" {
        		S[num - 1] = true;
        	} S[num - 1] = true S[num - 1] S num - 1 num 1 true if(mark.equals("H")){
        		H[num - 1] = true;
         	}else if(mark.equals("C")){
        		C[num - 1] = true;
        	}else if(mark.equals("D")){
        		D[num - 1] = true;
      		} mark.equals("H") mark.equals mark "H" {
        		H[num - 1] = true;
         	} H[num - 1] = true H[num - 1] H num - 1 num 1 true if(mark.equals("C")){
        		C[num - 1] = true;
        	}else if(mark.equals("D")){
        		D[num - 1] = true;
      		} mark.equals("C") mark.equals mark "C" {
        		C[num - 1] = true;
        	} C[num - 1] = true C[num - 1] C num - 1 num 1 true if(mark.equals("D")){
        		D[num - 1] = true;
      		} mark.equals("D") mark.equals mark "D" {
        		D[num - 1] = true;
      		} D[num - 1] = true D[num - 1] D num - 1 num 1 true for(int set = 0;set < 13; set++){
    		if(S[set] == false){
    			System.out.println("S" + " " + (set + 1));
    		}
    	} int set = 0; int set = 0; set 0 set < 13 set 13 set++ set++ set {
    		if(S[set] == false){
    			System.out.println("S" + " " + (set + 1));
    		}
    	} {
    		if(S[set] == false){
    			System.out.println("S" + " " + (set + 1));
    		}
    	} if(S[set] == false){
    			System.out.println("S" + " " + (set + 1));
    		} S[set] == false S[set] S set false {
    			System.out.println("S" + " " + (set + 1));
    		} System.out.println("S" + " " + (set + 1)) System.out.println System.out System System.out "S" + " " + (set + 1) "S" + " " + (set + 1) "S" " " (set + 1) set 1 for(int set = 0;set < 13; set++){
    		if(H[set] == false){
    			System.out.println("H" + " " + (set + 1));
    		}
    	} int set = 0; int set = 0; set 0 set < 13 set 13 set++ set++ set {
    		if(H[set] == false){
    			System.out.println("H" + " " + (set + 1));
    		}
    	} {
    		if(H[set] == false){
    			System.out.println("H" + " " + (set + 1));
    		}
    	} if(H[set] == false){
    			System.out.println("H" + " " + (set + 1));
    		} H[set] == false H[set] H set false {
    			System.out.println("H" + " " + (set + 1));
    		} System.out.println("H" + " " + (set + 1)) System.out.println System.out System System.out "H" + " " + (set + 1) "H" + " " + (set + 1) "H" " " (set + 1) set 1 for(int set = 0;set < 13; set++){
    		if(C[set] == false){
    			System.out.println("C" + " " + (set + 1));
    		}
    	} int set = 0; int set = 0; set 0 set < 13 set 13 set++ set++ set {
    		if(C[set] == false){
    			System.out.println("C" + " " + (set + 1));
    		}
    	} {
    		if(C[set] == false){
    			System.out.println("C" + " " + (set + 1));
    		}
    	} if(C[set] == false){
    			System.out.println("C" + " " + (set + 1));
    		} C[set] == false C[set] C set false {
    			System.out.println("C" + " " + (set + 1));
    		} System.out.println("C" + " " + (set + 1)) System.out.println System.out System System.out "C" + " " + (set + 1) "C" + " " + (set + 1) "C" " " (set + 1) set 1 for(int set = 0;set < 13; set++){
    		if(D[set] == false){
    			System.out.println("D" + " " + (set + 1));
    		}
    	} int set = 0; int set = 0; set 0 set < 13 set 13 set++ set++ set {
    		if(D[set] == false){
    			System.out.println("D" + " " + (set + 1));
    		}
    	} {
    		if(D[set] == false){
    			System.out.println("D" + " " + (set + 1));
    		}
    	} if(D[set] == false){
    			System.out.println("D" + " " + (set + 1));
    		} D[set] == false D[set] D set false {
    			System.out.println("D" + " " + (set + 1));
    		} System.out.println("D" + " " + (set + 1)) System.out.println System.out System System.out "D" + " " + (set + 1) "D" + " " + (set + 1) "D" " " (set + 1) set 1 String[] args args public class Main {
	public void maain(){

	}

	public static void main(String[] args) throws IOException {
		// TODO ?????????????????????????????????????????????
		//?????????????¨?????????£?¨?
		boolean[] S = new boolean[13];
		boolean[] H = new boolean[13];
		boolean[] C = new boolean[13];
		boolean[] D = new boolean[13];

		//1???????????\????????¢
		InputStreamReader isr = new InputStreamReader(System.in);
        BufferedReader br = new BufferedReader(isr);

        String[] input = br.readLine().split(" ");
        int n = Integer.parseInt(input[0]);

        //2???????????\????????¢
        for(int set = 0;set < n; set++ ){
        	String[] input2 = br.readLine().split(" ");
        	String mark = input2[0];
        	int num = Integer.parseInt(input2[1]);

        	//?????£?????????????????????true???????????????
        	if(mark.equals("S")){
        		S[num - 1] = true;
        	}else if(mark.equals("H")){
        		H[num - 1] = true;
         	}else if(mark.equals("C")){
        		C[num - 1] = true;
        	}else if(mark.equals("D")){
        		D[num - 1] = true;
      		}
        }

        //?????£?????????????????????????????¢?????¨???????????????
    	for(int set = 0;set < 13; set++){
    		if(S[set] == false){
    			System.out.println("S" + " " + (set + 1));
    		}
    	}
    	for(int set = 0;set < 13; set++){
    		if(H[set] == false){
    			System.out.println("H" + " " + (set + 1));
    		}
    	}
    	for(int set = 0;set < 13; set++){
    		if(C[set] == false){
    			System.out.println("C" + " " + (set + 1));
    		}
    	}
    	for(int set = 0;set < 13; set++){
    		if(D[set] == false){
    			System.out.println("D" + " " + (set + 1));
    		}
    	}
	}
} public class Main {
	public void maain(){

	}

	public static void main(String[] args) throws IOException {
		// TODO ?????????????????????????????????????????????
		//?????????????¨?????????£?¨?
		boolean[] S = new boolean[13];
		boolean[] H = new boolean[13];
		boolean[] C = new boolean[13];
		boolean[] D = new boolean[13];

		//1???????????\????????¢
		InputStreamReader isr = new InputStreamReader(System.in);
        BufferedReader br = new BufferedReader(isr);

        String[] input = br.readLine().split(" ");
        int n = Integer.parseInt(input[0]);

        //2???????????\????????¢
        for(int set = 0;set < n; set++ ){
        	String[] input2 = br.readLine().split(" ");
        	String mark = input2[0];
        	int num = Integer.parseInt(input2[1]);

        	//?????£?????????????????????true???????????????
        	if(mark.equals("S")){
        		S[num - 1] = true;
        	}else if(mark.equals("H")){
        		H[num - 1] = true;
         	}else if(mark.equals("C")){
        		C[num - 1] = true;
        	}else if(mark.equals("D")){
        		D[num - 1] = true;
      		}
        }

        //?????£?????????????????????????????¢?????¨???????????????
    	for(int set = 0;set < 13; set++){
    		if(S[set] == false){
    			System.out.println("S" + " " + (set + 1));
    		}
    	}
    	for(int set = 0;set < 13; set++){
    		if(H[set] == false){
    			System.out.println("H" + " " + (set + 1));
    		}
    	}
    	for(int set = 0;set < 13; set++){
    		if(C[set] == false){
    			System.out.println("C" + " " + (set + 1));
    		}
    	}
    	for(int set = 0;set < 13; set++){
    		if(D[set] == false){
    			System.out.println("D" + " " + (set + 1));
    		}
    	}
	}
} Main
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class Main {
	public void maain(){

	}

	public static void main(String[] args) throws IOException {
		// TODO ?????????????????????????????????????????????
		//?????????????¨?????????£?¨?
		boolean[] S = new boolean[13];
		boolean[] H = new boolean[13];
		boolean[] C = new boolean[13];
		boolean[] D = new boolean[13];

		//1???????????\????????¢
		InputStreamReader isr = new InputStreamReader(System.in);
        BufferedReader br = new BufferedReader(isr);

        String[] input = br.readLine().split(" ");
        int n = Integer.parseInt(input[0]);

        //2???????????\????????¢
        for(int set = 0;set < n; set++ ){
        	String[] input2 = br.readLine().split(" ");
        	String mark = input2[0];
        	int num = Integer.parseInt(input2[1]);

        	//?????£?????????????????????true???????????????
        	if(mark.equals("S")){
        		S[num - 1] = true;
        	}else if(mark.equals("H")){
        		H[num - 1] = true;
         	}else if(mark.equals("C")){
        		C[num - 1] = true;
        	}else if(mark.equals("D")){
        		D[num - 1] = true;
      		}
        }

        //?????£?????????????????????????????¢?????¨???????????????
    	for(int set = 0;set < 13; set++){
    		if(S[set] == false){
    			System.out.println("S" + " " + (set + 1));
    		}
    	}
    	for(int set = 0;set < 13; set++){
    		if(H[set] == false){
    			System.out.println("H" + " " + (set + 1));
    		}
    	}
    	for(int set = 0;set < 13; set++){
    		if(C[set] == false){
    			System.out.println("C" + " " + (set + 1));
    		}
    	}
    	for(int set = 0;set < 13; set++){
    		if(D[set] == false){
    			System.out.println("D" + " " + (set + 1));
    		}
    	}
	}
}