import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        int[][] l = new int[4][13];

        for(int i = 0; i < a; i++) {
        	String cardType = sc.next();
        	int cardNum = sc.nextInt();

        	switch(cardType) {
        	case "S":
        		l[0][cardNum-1] = 1;
        		break;
        	case "H":
        		l[1][cardNum-1] = 1;
        		break;
        	case "C":
        		l[2][cardNum-1] = 1;
        		break;
        	case "D":
        		l[3][cardNum-1] = 1;
        		break;
        	}
        }

        for(int i = 0; i < 4; i++) {

        	for(int j = 0; j < 13; j++) {

        		if(l[i][j] == 0) {

        			switch(i) {
        			case 0:
        				System.out.println("S " + (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;
        			}
        		}
        	}
        }
	}
}
 import java.util.Scanner; Scanner java.util public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        int[][] l = new int[4][13];

        for(int i = 0; i < a; i++) {
        	String cardType = sc.next();
        	int cardNum = sc.nextInt();

        	switch(cardType) {
        	case "S":
        		l[0][cardNum-1] = 1;
        		break;
        	case "H":
        		l[1][cardNum-1] = 1;
        		break;
        	case "C":
        		l[2][cardNum-1] = 1;
        		break;
        	case "D":
        		l[3][cardNum-1] = 1;
        		break;
        	}
        }

        for(int i = 0; i < 4; i++) {

        	for(int j = 0; j < 13; j++) {

        		if(l[i][j] == 0) {

        			switch(i) {
        			case 0:
        				System.out.println("S " + (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;
        			}
        		}
        	}
        }
	}
} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        int[][] l = new int[4][13];

        for(int i = 0; i < a; i++) {
        	String cardType = sc.next();
        	int cardNum = sc.nextInt();

        	switch(cardType) {
        	case "S":
        		l[0][cardNum-1] = 1;
        		break;
        	case "H":
        		l[1][cardNum-1] = 1;
        		break;
        	case "C":
        		l[2][cardNum-1] = 1;
        		break;
        	case "D":
        		l[3][cardNum-1] = 1;
        		break;
        	}
        }

        for(int i = 0; i < 4; i++) {

        	for(int j = 0; j < 13; j++) {

        		if(l[i][j] == 0) {

        			switch(i) {
        			case 0:
        				System.out.println("S " + (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;
        			}
        		}
        	}
        }
	} main {
		Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        int[][] l = new int[4][13];

        for(int i = 0; i < a; i++) {
        	String cardType = sc.next();
        	int cardNum = sc.nextInt();

        	switch(cardType) {
        	case "S":
        		l[0][cardNum-1] = 1;
        		break;
        	case "H":
        		l[1][cardNum-1] = 1;
        		break;
        	case "C":
        		l[2][cardNum-1] = 1;
        		break;
        	case "D":
        		l[3][cardNum-1] = 1;
        		break;
        	}
        }

        for(int i = 0; i < 4; i++) {

        	for(int j = 0; j < 13; j++) {

        		if(l[i][j] == 0) {

        			switch(i) {
        			case 0:
        				System.out.println("S " + (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;
        			}
        		}
        	}
        }
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int a = sc.nextInt(); a sc.nextInt() sc.nextInt sc int[][] l = new int[4][13]; l new int[4][13] 4 13 for(int i = 0; i < a; i++) {
        	String cardType = sc.next();
        	int cardNum = sc.nextInt();

        	switch(cardType) {
        	case "S":
        		l[0][cardNum-1] = 1;
        		break;
        	case "H":
        		l[1][cardNum-1] = 1;
        		break;
        	case "C":
        		l[2][cardNum-1] = 1;
        		break;
        	case "D":
        		l[3][cardNum-1] = 1;
        		break;
        	}
        } int i = 0; int i = 0; i 0 i < a i a i++ i++ i {
        	String cardType = sc.next();
        	int cardNum = sc.nextInt();

        	switch(cardType) {
        	case "S":
        		l[0][cardNum-1] = 1;
        		break;
        	case "H":
        		l[1][cardNum-1] = 1;
        		break;
        	case "C":
        		l[2][cardNum-1] = 1;
        		break;
        	case "D":
        		l[3][cardNum-1] = 1;
        		break;
        	}
        } {
        	String cardType = sc.next();
        	int cardNum = sc.nextInt();

        	switch(cardType) {
        	case "S":
        		l[0][cardNum-1] = 1;
        		break;
        	case "H":
        		l[1][cardNum-1] = 1;
        		break;
        	case "C":
        		l[2][cardNum-1] = 1;
        		break;
        	case "D":
        		l[3][cardNum-1] = 1;
        		break;
        	}
        } String cardType = sc.next(); cardType sc.next() sc.next sc int cardNum = sc.nextInt(); cardNum sc.nextInt() sc.nextInt sc switch(cardType) {
        	case "S":
        		l[0][cardNum-1] = 1;
        		break;
        	case "H":
        		l[1][cardNum-1] = 1;
        		break;
        	case "C":
        		l[2][cardNum-1] = 1;
        		break;
        	case "D":
        		l[3][cardNum-1] = 1;
        		break;
        	} cardType case "S": "S" case "S": l[0][cardNum-1] = 1 l[0][cardNum-1] l[0] l 0 cardNum-1 cardNum 1 1 break; case "H": "H" case "H": l[1][cardNum-1] = 1 l[1][cardNum-1] l[1] l 1 cardNum-1 cardNum 1 1 break; case "C": "C" case "C": l[2][cardNum-1] = 1 l[2][cardNum-1] l[2] l 2 cardNum-1 cardNum 1 1 break; case "D": "D" case "D": l[3][cardNum-1] = 1 l[3][cardNum-1] l[3] l 3 cardNum-1 cardNum 1 1 break; for(int i = 0; i < 4; i++) {

        	for(int j = 0; j < 13; j++) {

        		if(l[i][j] == 0) {

        			switch(i) {
        			case 0:
        				System.out.println("S " + (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(l[i][j] == 0) {

        			switch(i) {
        			case 0:
        				System.out.println("S " + (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(l[i][j] == 0) {

        			switch(i) {
        			case 0:
        				System.out.println("S " + (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(l[i][j] == 0) {

        			switch(i) {
        			case 0:
        				System.out.println("S " + (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(l[i][j] == 0) {

        			switch(i) {
        			case 0:
        				System.out.println("S " + (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(l[i][j] == 0) {

        			switch(i) {
        			case 0:
        				System.out.println("S " + (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(l[i][j] == 0) {

        			switch(i) {
        			case 0:
        				System.out.println("S " + (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;
        			}
        		} l[i][j] == 0 l[i][j] l[i] l i j 0 {

        			switch(i) {
        			case 0:
        				System.out.println("S " + (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) );
        				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) {
		Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        int[][] l = new int[4][13];

        for(int i = 0; i < a; i++) {
        	String cardType = sc.next();
        	int cardNum = sc.nextInt();

        	switch(cardType) {
        	case "S":
        		l[0][cardNum-1] = 1;
        		break;
        	case "H":
        		l[1][cardNum-1] = 1;
        		break;
        	case "C":
        		l[2][cardNum-1] = 1;
        		break;
        	case "D":
        		l[3][cardNum-1] = 1;
        		break;
        	}
        }

        for(int i = 0; i < 4; i++) {

        	for(int j = 0; j < 13; j++) {

        		if(l[i][j] == 0) {

        			switch(i) {
        			case 0:
        				System.out.println("S " + (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;
        			}
        		}
        	}
        }
	}
} public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        int[][] l = new int[4][13];

        for(int i = 0; i < a; i++) {
        	String cardType = sc.next();
        	int cardNum = sc.nextInt();

        	switch(cardType) {
        	case "S":
        		l[0][cardNum-1] = 1;
        		break;
        	case "H":
        		l[1][cardNum-1] = 1;
        		break;
        	case "C":
        		l[2][cardNum-1] = 1;
        		break;
        	case "D":
        		l[3][cardNum-1] = 1;
        		break;
        	}
        }

        for(int i = 0; i < 4; i++) {

        	for(int j = 0; j < 13; j++) {

        		if(l[i][j] == 0) {

        			switch(i) {
        			case 0:
        				System.out.println("S " + (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;
        			}
        		}
        	}
        }
	}
} Main
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        int[][] l = new int[4][13];

        for(int i = 0; i < a; i++) {
        	String cardType = sc.next();
        	int cardNum = sc.nextInt();

        	switch(cardType) {
        	case "S":
        		l[0][cardNum-1] = 1;
        		break;
        	case "H":
        		l[1][cardNum-1] = 1;
        		break;
        	case "C":
        		l[2][cardNum-1] = 1;
        		break;
        	case "D":
        		l[3][cardNum-1] = 1;
        		break;
        	}
        }

        for(int i = 0; i < 4; i++) {

        	for(int j = 0; j < 13; j++) {

        		if(l[i][j] == 0) {

        			switch(i) {
        			case 0:
        				System.out.println("S " + (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;
        			}
        		}
        	}
        }
	}
}

