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

public class Main{
    
    static int getMark(String mark){
        switch(mark){
            case "S":   return 0;
            case "H":   return 1;
            case "C":   return 2;
            case "D":   return 3;
            default :   return -1;
        }
    }

    static String getMark(int mark){
        switch(mark){
            case 0:   return "S";
            case 1:   return "H";
            case 2:   return "C";
            case 3:   return "D";
            default :   return "";
        }
    }

    public static void main(String[] args) throws IOException{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));

        int[][] cards = new int[4][13];

        int num = Integer.parseInt(br.readLine());

        for(int i = 0; i < num; i++){
            String[] input = br.readLine().split(" ");
            
            int mark = getMark(input[0]);

            cards[mark][Integer.parseInt(input[1])-1] = 1;
        }

        for(int i = 0; i < 4; i++){
            for(int j = 0; j < 13; j++){
                if(cards[i][j] == 0) System.out.println(getMark(i) + " " + (j+1));
            }
        }

    }
} import java.io.IOException; IOException java.io import java.io.InputStreamReader; InputStreamReader java.io import java.io.BufferedReader; BufferedReader java.io public class Main{
    
    static int getMark(String mark){
        switch(mark){
            case "S":   return 0;
            case "H":   return 1;
            case "C":   return 2;
            case "D":   return 3;
            default :   return -1;
        }
    }

    static String getMark(int mark){
        switch(mark){
            case 0:   return "S";
            case 1:   return "H";
            case 2:   return "C";
            case 3:   return "D";
            default :   return "";
        }
    }

    public static void main(String[] args) throws IOException{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));

        int[][] cards = new int[4][13];

        int num = Integer.parseInt(br.readLine());

        for(int i = 0; i < num; i++){
            String[] input = br.readLine().split(" ");
            
            int mark = getMark(input[0]);

            cards[mark][Integer.parseInt(input[1])-1] = 1;
        }

        for(int i = 0; i < 4; i++){
            for(int j = 0; j < 13; j++){
                if(cards[i][j] == 0) System.out.println(getMark(i) + " " + (j+1));
            }
        }

    }
} Main static int getMark(String mark){
        switch(mark){
            case "S":   return 0;
            case "H":   return 1;
            case "C":   return 2;
            case "D":   return 3;
            default :   return -1;
        }
    } getMark {
        switch(mark){
            case "S":   return 0;
            case "H":   return 1;
            case "C":   return 2;
            case "D":   return 3;
            default :   return -1;
        }
    } switch(mark){
            case "S":   return 0;
            case "H":   return 1;
            case "C":   return 2;
            case "D":   return 3;
            default :   return -1;
        } mark case "S": "S" case "S": return 0; 0 case "H": "H" case "H": return 1; 1 case "C": "C" case "C": return 2; 2 case "D": "D" case "D": return 3; 3 default : default : return -1; -1 1 String mark mark static String getMark(int mark){
        switch(mark){
            case 0:   return "S";
            case 1:   return "H";
            case 2:   return "C";
            case 3:   return "D";
            default :   return "";
        }
    } getMark {
        switch(mark){
            case 0:   return "S";
            case 1:   return "H";
            case 2:   return "C";
            case 3:   return "D";
            default :   return "";
        }
    } switch(mark){
            case 0:   return "S";
            case 1:   return "H";
            case 2:   return "C";
            case 3:   return "D";
            default :   return "";
        } mark case 0: 0 case 0: return "S"; "S" case 1: 1 case 1: return "H"; "H" case 2: 2 case 2: return "C"; "C" case 3: 3 case 3: return "D"; "D" default : default : return ""; "" int mark mark public static void main(String[] args) throws IOException{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));

        int[][] cards = new int[4][13];

        int num = Integer.parseInt(br.readLine());

        for(int i = 0; i < num; i++){
            String[] input = br.readLine().split(" ");
            
            int mark = getMark(input[0]);

            cards[mark][Integer.parseInt(input[1])-1] = 1;
        }

        for(int i = 0; i < 4; i++){
            for(int j = 0; j < 13; j++){
                if(cards[i][j] == 0) System.out.println(getMark(i) + " " + (j+1));
            }
        }

    } main {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));

        int[][] cards = new int[4][13];

        int num = Integer.parseInt(br.readLine());

        for(int i = 0; i < num; i++){
            String[] input = br.readLine().split(" ");
            
            int mark = getMark(input[0]);

            cards[mark][Integer.parseInt(input[1])-1] = 1;
        }

        for(int i = 0; i < 4; i++){
            for(int j = 0; j < 13; j++){
                if(cards[i][j] == 0) System.out.println(getMark(i) + " " + (j+1));
            }
        }

    } BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) int[][] cards = new int[4][13]; cards new int[4][13] 4 13 int num = Integer.parseInt(br.readLine()); num Integer.parseInt(br.readLine()) Integer.parseInt Integer br.readLine() br.readLine br for(int i = 0; i < num; i++){
            String[] input = br.readLine().split(" ");
            
            int mark = getMark(input[0]);

            cards[mark][Integer.parseInt(input[1])-1] = 1;
        } int i = 0; int i = 0; i 0 i < num i num i++ i++ i {
            String[] input = br.readLine().split(" ");
            
            int mark = getMark(input[0]);

            cards[mark][Integer.parseInt(input[1])-1] = 1;
        } {
            String[] input = br.readLine().split(" ");
            
            int mark = getMark(input[0]);

            cards[mark][Integer.parseInt(input[1])-1] = 1;
        } String[] input = br.readLine().split(" "); input br.readLine().split(" ") br.readLine().split br.readLine() br.readLine br " " int mark = getMark(input[0]); mark getMark(input[0]) getMark input[0] input 0 cards[mark][Integer.parseInt(input[1])-1] = 1 cards[mark][Integer.parseInt(input[1])-1] cards[mark] cards mark Integer.parseInt(input[1])-1 Integer.parseInt(input[1]) Integer.parseInt Integer input[1] input 1 1 1 for(int i = 0; i < 4; i++){
            for(int j = 0; j < 13; j++){
                if(cards[i][j] == 0) System.out.println(getMark(i) + " " + (j+1));
            }
        } int i = 0; int i = 0; i 0 i < 4 i 4 i++ i++ i {
            for(int j = 0; j < 13; j++){
                if(cards[i][j] == 0) System.out.println(getMark(i) + " " + (j+1));
            }
        } {
            for(int j = 0; j < 13; j++){
                if(cards[i][j] == 0) System.out.println(getMark(i) + " " + (j+1));
            }
        } for(int j = 0; j < 13; j++){
                if(cards[i][j] == 0) System.out.println(getMark(i) + " " + (j+1));
            } int j = 0; int j = 0; j 0 j < 13 j 13 j++ j++ j {
                if(cards[i][j] == 0) System.out.println(getMark(i) + " " + (j+1));
            } {
                if(cards[i][j] == 0) System.out.println(getMark(i) + " " + (j+1));
            } if(cards[i][j] == 0) System.out.println(getMark(i) + " " + (j+1)); cards[i][j] == 0 cards[i][j] cards[i] cards i j 0 System.out.println(getMark(i) + " " + (j+1)) System.out.println System.out System System.out getMark(i) + " " + (j+1) getMark(i) + " " + (j+1) getMark(i) getMark i " " (j+1) j 1 String[] args args public class Main{
    
    static int getMark(String mark){
        switch(mark){
            case "S":   return 0;
            case "H":   return 1;
            case "C":   return 2;
            case "D":   return 3;
            default :   return -1;
        }
    }

    static String getMark(int mark){
        switch(mark){
            case 0:   return "S";
            case 1:   return "H";
            case 2:   return "C";
            case 3:   return "D";
            default :   return "";
        }
    }

    public static void main(String[] args) throws IOException{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));

        int[][] cards = new int[4][13];

        int num = Integer.parseInt(br.readLine());

        for(int i = 0; i < num; i++){
            String[] input = br.readLine().split(" ");
            
            int mark = getMark(input[0]);

            cards[mark][Integer.parseInt(input[1])-1] = 1;
        }

        for(int i = 0; i < 4; i++){
            for(int j = 0; j < 13; j++){
                if(cards[i][j] == 0) System.out.println(getMark(i) + " " + (j+1));
            }
        }

    }
} public class Main{
    
    static int getMark(String mark){
        switch(mark){
            case "S":   return 0;
            case "H":   return 1;
            case "C":   return 2;
            case "D":   return 3;
            default :   return -1;
        }
    }

    static String getMark(int mark){
        switch(mark){
            case 0:   return "S";
            case 1:   return "H";
            case 2:   return "C";
            case 3:   return "D";
            default :   return "";
        }
    }

    public static void main(String[] args) throws IOException{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));

        int[][] cards = new int[4][13];

        int num = Integer.parseInt(br.readLine());

        for(int i = 0; i < num; i++){
            String[] input = br.readLine().split(" ");
            
            int mark = getMark(input[0]);

            cards[mark][Integer.parseInt(input[1])-1] = 1;
        }

        for(int i = 0; i < 4; i++){
            for(int j = 0; j < 13; j++){
                if(cards[i][j] == 0) System.out.println(getMark(i) + " " + (j+1));
            }
        }

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

public class Main{
    
    static int getMark(String mark){
        switch(mark){
            case "S":   return 0;
            case "H":   return 1;
            case "C":   return 2;
            case "D":   return 3;
            default :   return -1;
        }
    }

    static String getMark(int mark){
        switch(mark){
            case 0:   return "S";
            case 1:   return "H";
            case 2:   return "C";
            case 3:   return "D";
            default :   return "";
        }
    }

    public static void main(String[] args) throws IOException{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));

        int[][] cards = new int[4][13];

        int num = Integer.parseInt(br.readLine());

        for(int i = 0; i < num; i++){
            String[] input = br.readLine().split(" ");
            
            int mark = getMark(input[0]);

            cards[mark][Integer.parseInt(input[1])-1] = 1;
        }

        for(int i = 0; i < 4; i++){
            for(int j = 0; j < 13; j++){
                if(cards[i][j] == 0) System.out.println(getMark(i) + " " + (j+1));
            }
        }

    }
}