import java.util.Scanner;


public class Main {
	

	public static void main(String[] args) {
		Scanner stdIn = new Scanner(System.in);
		boolean[][] a = new boolean[4][13];
		int n = stdIn.nextInt();
		for(int i = 0; i < n; i++) {
			String p = stdIn.next();
			int v = stdIn.nextInt();
			
			if(p.equals("S")) {
				a[0][v-1] = true;
			}
			else if (p.equals("H")) {	
				a[1][v-1] = true;
			}
			else if (p.equals("C")) {	
				a[2][v-1] = true;
			}
			else {
				a[3][v-1] = true;
			}
		}
		
		for(int i = 0; i < 4; i++) {
			for(int j = 0; j < 13; j++) {
				if(!a[i][j]) {
					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 stdIn = new Scanner(System.in);
		boolean[][] a = new boolean[4][13];
		int n = stdIn.nextInt();
		for(int i = 0; i < n; i++) {
			String p = stdIn.next();
			int v = stdIn.nextInt();
			
			if(p.equals("S")) {
				a[0][v-1] = true;
			}
			else if (p.equals("H")) {	
				a[1][v-1] = true;
			}
			else if (p.equals("C")) {	
				a[2][v-1] = true;
			}
			else {
				a[3][v-1] = true;
			}
		}
		
		for(int i = 0; i < 4; i++) {
			for(int j = 0; j < 13; j++) {
				if(!a[i][j]) {
					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 stdIn = new Scanner(System.in);
		boolean[][] a = new boolean[4][13];
		int n = stdIn.nextInt();
		for(int i = 0; i < n; i++) {
			String p = stdIn.next();
			int v = stdIn.nextInt();
			
			if(p.equals("S")) {
				a[0][v-1] = true;
			}
			else if (p.equals("H")) {	
				a[1][v-1] = true;
			}
			else if (p.equals("C")) {	
				a[2][v-1] = true;
			}
			else {
				a[3][v-1] = true;
			}
		}
		
		for(int i = 0; i < 4; i++) {
			for(int j = 0; j < 13; j++) {
				if(!a[i][j]) {
					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 stdIn = new Scanner(System.in);
		boolean[][] a = new boolean[4][13];
		int n = stdIn.nextInt();
		for(int i = 0; i < n; i++) {
			String p = stdIn.next();
			int v = stdIn.nextInt();
			
			if(p.equals("S")) {
				a[0][v-1] = true;
			}
			else if (p.equals("H")) {	
				a[1][v-1] = true;
			}
			else if (p.equals("C")) {	
				a[2][v-1] = true;
			}
			else {
				a[3][v-1] = true;
			}
		}
		
		for(int i = 0; i < 4; i++) {
			for(int j = 0; j < 13; j++) {
				if(!a[i][j]) {
					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 stdIn = new Scanner(System.in); stdIn new Scanner(System.in) boolean[][] a = new boolean[4][13]; a new boolean[4][13] 4 13 int n = stdIn.nextInt(); n stdIn.nextInt() stdIn.nextInt stdIn for(int i = 0; i < n; i++) {
			String p = stdIn.next();
			int v = stdIn.nextInt();
			
			if(p.equals("S")) {
				a[0][v-1] = true;
			}
			else if (p.equals("H")) {	
				a[1][v-1] = true;
			}
			else if (p.equals("C")) {	
				a[2][v-1] = true;
			}
			else {
				a[3][v-1] = true;
			}
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			String p = stdIn.next();
			int v = stdIn.nextInt();
			
			if(p.equals("S")) {
				a[0][v-1] = true;
			}
			else if (p.equals("H")) {	
				a[1][v-1] = true;
			}
			else if (p.equals("C")) {	
				a[2][v-1] = true;
			}
			else {
				a[3][v-1] = true;
			}
		} {
			String p = stdIn.next();
			int v = stdIn.nextInt();
			
			if(p.equals("S")) {
				a[0][v-1] = true;
			}
			else if (p.equals("H")) {	
				a[1][v-1] = true;
			}
			else if (p.equals("C")) {	
				a[2][v-1] = true;
			}
			else {
				a[3][v-1] = true;
			}
		} String p = stdIn.next(); p stdIn.next() stdIn.next stdIn int v = stdIn.nextInt(); v stdIn.nextInt() stdIn.nextInt stdIn if(p.equals("S")) {
				a[0][v-1] = true;
			}
			else if (p.equals("H")) {	
				a[1][v-1] = true;
			}
			else if (p.equals("C")) {	
				a[2][v-1] = true;
			}
			else {
				a[3][v-1] = true;
			} p.equals("S") p.equals p "S" {
				a[0][v-1] = true;
			} a[0][v-1] = true a[0][v-1] a[0] a 0 v-1 v 1 true if (p.equals("H")) {	
				a[1][v-1] = true;
			}
			else if (p.equals("C")) {	
				a[2][v-1] = true;
			}
			else {
				a[3][v-1] = true;
			} p.equals("H") p.equals p "H" {	
				a[1][v-1] = true;
			} a[1][v-1] = true a[1][v-1] a[1] a 1 v-1 v 1 true if (p.equals("C")) {	
				a[2][v-1] = true;
			}
			else {
				a[3][v-1] = true;
			} p.equals("C") p.equals p "C" {	
				a[2][v-1] = true;
			} a[2][v-1] = true a[2][v-1] a[2] a 2 v-1 v 1 true {
				a[3][v-1] = true;
			} a[3][v-1] = true a[3][v-1] a[3] a 3 v-1 v 1 true for(int i = 0; i < 4; i++) {
			for(int j = 0; j < 13; j++) {
				if(!a[i][j]) {
					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(!a[i][j]) {
					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(!a[i][j]) {
					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(!a[i][j]) {
					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(!a[i][j]) {
					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(!a[i][j]) {
					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(!a[i][j]) {
					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;
					}
				} !a[i][j] a[i][j] a[i] a i j {
					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 stdIn = new Scanner(System.in);
		boolean[][] a = new boolean[4][13];
		int n = stdIn.nextInt();
		for(int i = 0; i < n; i++) {
			String p = stdIn.next();
			int v = stdIn.nextInt();
			
			if(p.equals("S")) {
				a[0][v-1] = true;
			}
			else if (p.equals("H")) {	
				a[1][v-1] = true;
			}
			else if (p.equals("C")) {	
				a[2][v-1] = true;
			}
			else {
				a[3][v-1] = true;
			}
		}
		
		for(int i = 0; i < 4; i++) {
			for(int j = 0; j < 13; j++) {
				if(!a[i][j]) {
					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 stdIn = new Scanner(System.in);
		boolean[][] a = new boolean[4][13];
		int n = stdIn.nextInt();
		for(int i = 0; i < n; i++) {
			String p = stdIn.next();
			int v = stdIn.nextInt();
			
			if(p.equals("S")) {
				a[0][v-1] = true;
			}
			else if (p.equals("H")) {	
				a[1][v-1] = true;
			}
			else if (p.equals("C")) {	
				a[2][v-1] = true;
			}
			else {
				a[3][v-1] = true;
			}
		}
		
		for(int i = 0; i < 4; i++) {
			for(int j = 0; j < 13; j++) {
				if(!a[i][j]) {
					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 stdIn = new Scanner(System.in);
		boolean[][] a = new boolean[4][13];
		int n = stdIn.nextInt();
		for(int i = 0; i < n; i++) {
			String p = stdIn.next();
			int v = stdIn.nextInt();
			
			if(p.equals("S")) {
				a[0][v-1] = true;
			}
			else if (p.equals("H")) {	
				a[1][v-1] = true;
			}
			else if (p.equals("C")) {	
				a[2][v-1] = true;
			}
			else {
				a[3][v-1] = true;
			}
		}
		
		for(int i = 0; i < 4; i++) {
			for(int j = 0; j < 13; j++) {
				if(!a[i][j]) {
					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;
					}
				}
			}
		}
	}

}