import java.util.*;

class Main{
	public static void main(String args[]){
		Scanner sc = new Scanner(System.in);
		int[][] isExist = new int[4][13];
		char ch;
		
		for(int i = 0; i < 4; i++)
			for(int j = 0; j < 13; j++)
				isExist[i][j] = 0;
		
		int n = sc.nextInt();
		
		for(int i = 0; i < n; i++){
			String mark = sc.next();
			int num = sc.nextInt();
			
			if(mark.equals("S"))
				isExist[0][num-1] = 1;
			else if(mark.equals("H"))
				isExist[1][num-1] = 1;
			else if(mark.equals("C"))
				isExist[2][num-1] = 1;
			else
				isExist[3][num-1] = 1;
		}
		
		for(int i = 0; i < 4; i++){
			if(i == 0)
				ch = 'S';
			else if(i == 1)
				ch = 'H';
			else if(i == 2)
				ch = 'C';
			else
				ch = 'D';
			
			for(int j = 0; j < 13; j++){
				if(isExist[i][j] == 0)
					System.out.println(ch + " " + (j + 1));
			}
		}
	}
} import java.util.*; util.* java class Main{
	public static void main(String args[]){
		Scanner sc = new Scanner(System.in);
		int[][] isExist = new int[4][13];
		char ch;
		
		for(int i = 0; i < 4; i++)
			for(int j = 0; j < 13; j++)
				isExist[i][j] = 0;
		
		int n = sc.nextInt();
		
		for(int i = 0; i < n; i++){
			String mark = sc.next();
			int num = sc.nextInt();
			
			if(mark.equals("S"))
				isExist[0][num-1] = 1;
			else if(mark.equals("H"))
				isExist[1][num-1] = 1;
			else if(mark.equals("C"))
				isExist[2][num-1] = 1;
			else
				isExist[3][num-1] = 1;
		}
		
		for(int i = 0; i < 4; i++){
			if(i == 0)
				ch = 'S';
			else if(i == 1)
				ch = 'H';
			else if(i == 2)
				ch = 'C';
			else
				ch = 'D';
			
			for(int j = 0; j < 13; j++){
				if(isExist[i][j] == 0)
					System.out.println(ch + " " + (j + 1));
			}
		}
	}
} Main public static void main(String args[]){
		Scanner sc = new Scanner(System.in);
		int[][] isExist = new int[4][13];
		char ch;
		
		for(int i = 0; i < 4; i++)
			for(int j = 0; j < 13; j++)
				isExist[i][j] = 0;
		
		int n = sc.nextInt();
		
		for(int i = 0; i < n; i++){
			String mark = sc.next();
			int num = sc.nextInt();
			
			if(mark.equals("S"))
				isExist[0][num-1] = 1;
			else if(mark.equals("H"))
				isExist[1][num-1] = 1;
			else if(mark.equals("C"))
				isExist[2][num-1] = 1;
			else
				isExist[3][num-1] = 1;
		}
		
		for(int i = 0; i < 4; i++){
			if(i == 0)
				ch = 'S';
			else if(i == 1)
				ch = 'H';
			else if(i == 2)
				ch = 'C';
			else
				ch = 'D';
			
			for(int j = 0; j < 13; j++){
				if(isExist[i][j] == 0)
					System.out.println(ch + " " + (j + 1));
			}
		}
	} main {
		Scanner sc = new Scanner(System.in);
		int[][] isExist = new int[4][13];
		char ch;
		
		for(int i = 0; i < 4; i++)
			for(int j = 0; j < 13; j++)
				isExist[i][j] = 0;
		
		int n = sc.nextInt();
		
		for(int i = 0; i < n; i++){
			String mark = sc.next();
			int num = sc.nextInt();
			
			if(mark.equals("S"))
				isExist[0][num-1] = 1;
			else if(mark.equals("H"))
				isExist[1][num-1] = 1;
			else if(mark.equals("C"))
				isExist[2][num-1] = 1;
			else
				isExist[3][num-1] = 1;
		}
		
		for(int i = 0; i < 4; i++){
			if(i == 0)
				ch = 'S';
			else if(i == 1)
				ch = 'H';
			else if(i == 2)
				ch = 'C';
			else
				ch = 'D';
			
			for(int j = 0; j < 13; j++){
				if(isExist[i][j] == 0)
					System.out.println(ch + " " + (j + 1));
			}
		}
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int[][] isExist = new int[4][13]; isExist new int[4][13] 4 13 char ch; ch for(int i = 0; i < 4; i++)
			for(int j = 0; j < 13; j++)
				isExist[i][j] = 0; int i = 0; int i = 0; i 0 i < 4 i 4 i++ i++ i for(int j = 0; j < 13; j++)
				isExist[i][j] = 0; for(int j = 0; j < 13; j++)
				isExist[i][j] = 0; int j = 0; int j = 0; j 0 j < 13 j 13 j++ j++ j isExist[i][j] = 0; isExist[i][j] = 0 isExist[i][j] isExist[i] isExist i j 0 int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc for(int i = 0; i < n; i++){
			String mark = sc.next();
			int num = sc.nextInt();
			
			if(mark.equals("S"))
				isExist[0][num-1] = 1;
			else if(mark.equals("H"))
				isExist[1][num-1] = 1;
			else if(mark.equals("C"))
				isExist[2][num-1] = 1;
			else
				isExist[3][num-1] = 1;
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			String mark = sc.next();
			int num = sc.nextInt();
			
			if(mark.equals("S"))
				isExist[0][num-1] = 1;
			else if(mark.equals("H"))
				isExist[1][num-1] = 1;
			else if(mark.equals("C"))
				isExist[2][num-1] = 1;
			else
				isExist[3][num-1] = 1;
		} {
			String mark = sc.next();
			int num = sc.nextInt();
			
			if(mark.equals("S"))
				isExist[0][num-1] = 1;
			else if(mark.equals("H"))
				isExist[1][num-1] = 1;
			else if(mark.equals("C"))
				isExist[2][num-1] = 1;
			else
				isExist[3][num-1] = 1;
		} String mark = sc.next(); mark sc.next() sc.next sc int num = sc.nextInt(); num sc.nextInt() sc.nextInt sc if(mark.equals("S"))
				isExist[0][num-1] = 1;
			else if(mark.equals("H"))
				isExist[1][num-1] = 1;
			else if(mark.equals("C"))
				isExist[2][num-1] = 1;
			else
				isExist[3][num-1] = 1; mark.equals("S") mark.equals mark "S" isExist[0][num-1] = 1 isExist[0][num-1] isExist[0] isExist 0 num-1 num 1 1 if(mark.equals("H"))
				isExist[1][num-1] = 1;
			else if(mark.equals("C"))
				isExist[2][num-1] = 1;
			else
				isExist[3][num-1] = 1; mark.equals("H") mark.equals mark "H" isExist[1][num-1] = 1 isExist[1][num-1] isExist[1] isExist 1 num-1 num 1 1 if(mark.equals("C"))
				isExist[2][num-1] = 1;
			else
				isExist[3][num-1] = 1; mark.equals("C") mark.equals mark "C" isExist[2][num-1] = 1 isExist[2][num-1] isExist[2] isExist 2 num-1 num 1 1 isExist[3][num-1] = 1 isExist[3][num-1] isExist[3] isExist 3 num-1 num 1 1 for(int i = 0; i < 4; i++){
			if(i == 0)
				ch = 'S';
			else if(i == 1)
				ch = 'H';
			else if(i == 2)
				ch = 'C';
			else
				ch = 'D';
			
			for(int j = 0; j < 13; j++){
				if(isExist[i][j] == 0)
					System.out.println(ch + " " + (j + 1));
			}
		} int i = 0; int i = 0; i 0 i < 4 i 4 i++ i++ i {
			if(i == 0)
				ch = 'S';
			else if(i == 1)
				ch = 'H';
			else if(i == 2)
				ch = 'C';
			else
				ch = 'D';
			
			for(int j = 0; j < 13; j++){
				if(isExist[i][j] == 0)
					System.out.println(ch + " " + (j + 1));
			}
		} {
			if(i == 0)
				ch = 'S';
			else if(i == 1)
				ch = 'H';
			else if(i == 2)
				ch = 'C';
			else
				ch = 'D';
			
			for(int j = 0; j < 13; j++){
				if(isExist[i][j] == 0)
					System.out.println(ch + " " + (j + 1));
			}
		} if(i == 0)
				ch = 'S';
			else if(i == 1)
				ch = 'H';
			else if(i == 2)
				ch = 'C';
			else
				ch = 'D'; i == 0 i 0 ch = 'S' ch 'S' if(i == 1)
				ch = 'H';
			else if(i == 2)
				ch = 'C';
			else
				ch = 'D'; i == 1 i 1 ch = 'H' ch 'H' if(i == 2)
				ch = 'C';
			else
				ch = 'D'; i == 2 i 2 ch = 'C' ch 'C' ch = 'D' ch 'D' for(int j = 0; j < 13; j++){
				if(isExist[i][j] == 0)
					System.out.println(ch + " " + (j + 1));
			} int j = 0; int j = 0; j 0 j < 13 j 13 j++ j++ j {
				if(isExist[i][j] == 0)
					System.out.println(ch + " " + (j + 1));
			} {
				if(isExist[i][j] == 0)
					System.out.println(ch + " " + (j + 1));
			} if(isExist[i][j] == 0)
					System.out.println(ch + " " + (j + 1)); isExist[i][j] == 0 isExist[i][j] isExist[i] isExist i j 0 System.out.println(ch + " " + (j + 1)) System.out.println System.out System System.out ch + " " + (j + 1) ch + " " + (j + 1) ch " " (j + 1) j 1 String args[] args
import java.util.*;

class Main{
	public static void main(String args[]){
		Scanner sc = new Scanner(System.in);
		int[][] isExist = new int[4][13];
		char ch;
		
		for(int i = 0; i < 4; i++)
			for(int j = 0; j < 13; j++)
				isExist[i][j] = 0;
		
		int n = sc.nextInt();
		
		for(int i = 0; i < n; i++){
			String mark = sc.next();
			int num = sc.nextInt();
			
			if(mark.equals("S"))
				isExist[0][num-1] = 1;
			else if(mark.equals("H"))
				isExist[1][num-1] = 1;
			else if(mark.equals("C"))
				isExist[2][num-1] = 1;
			else
				isExist[3][num-1] = 1;
		}
		
		for(int i = 0; i < 4; i++){
			if(i == 0)
				ch = 'S';
			else if(i == 1)
				ch = 'H';
			else if(i == 2)
				ch = 'C';
			else
				ch = 'D';
			
			for(int j = 0; j < 13; j++){
				if(isExist[i][j] == 0)
					System.out.println(ch + " " + (j + 1));
			}
		}
	}
}