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

public class Main {
	public static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		String str = br.readLine();
		Boolean[][] is = new Boolean[4][13];
		for (int i = 0; i < 4; i++) {
			for (int j = 0; j < 13; j++) {
				is[i][j] = false;
			}
		}
		int n = Integer.parseInt(str);
		for (int i = 0; i < n; i++) {
			str = br.readLine();
			String[] card = str.split(" ");
			if (card[0].equals("S")) {
				int k = Integer.parseInt(card[1]);
				is[0][k - 1] = true;
			} else if (card[0].equals("H")) {
				int k = Integer.parseInt(card[1]);
				is[1][k - 1] = true;
			} else if (card[0].equals("C")) {
				int k = Integer.parseInt(card[1]);
				is[2][k - 1] = true;
			} else {
				int k = Integer.parseInt(card[1]);
				is[3][k - 1] = true;
			}
		}
		String[] mark = { "S", "H", "C", "D" };
		for (int i = 0; i < 4; i++) {
			for (int j = 0; j < 13; j++) {
				if (!is[i][j]) {
					System.out.println(mark[i] + " " + (j + 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 static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		String str = br.readLine();
		Boolean[][] is = new Boolean[4][13];
		for (int i = 0; i < 4; i++) {
			for (int j = 0; j < 13; j++) {
				is[i][j] = false;
			}
		}
		int n = Integer.parseInt(str);
		for (int i = 0; i < n; i++) {
			str = br.readLine();
			String[] card = str.split(" ");
			if (card[0].equals("S")) {
				int k = Integer.parseInt(card[1]);
				is[0][k - 1] = true;
			} else if (card[0].equals("H")) {
				int k = Integer.parseInt(card[1]);
				is[1][k - 1] = true;
			} else if (card[0].equals("C")) {
				int k = Integer.parseInt(card[1]);
				is[2][k - 1] = true;
			} else {
				int k = Integer.parseInt(card[1]);
				is[3][k - 1] = true;
			}
		}
		String[] mark = { "S", "H", "C", "D" };
		for (int i = 0; i < 4; i++) {
			for (int j = 0; j < 13; j++) {
				if (!is[i][j]) {
					System.out.println(mark[i] + " " + (j + 1));
				}
			}
		}
	}
} Main public static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		String str = br.readLine();
		Boolean[][] is = new Boolean[4][13];
		for (int i = 0; i < 4; i++) {
			for (int j = 0; j < 13; j++) {
				is[i][j] = false;
			}
		}
		int n = Integer.parseInt(str);
		for (int i = 0; i < n; i++) {
			str = br.readLine();
			String[] card = str.split(" ");
			if (card[0].equals("S")) {
				int k = Integer.parseInt(card[1]);
				is[0][k - 1] = true;
			} else if (card[0].equals("H")) {
				int k = Integer.parseInt(card[1]);
				is[1][k - 1] = true;
			} else if (card[0].equals("C")) {
				int k = Integer.parseInt(card[1]);
				is[2][k - 1] = true;
			} else {
				int k = Integer.parseInt(card[1]);
				is[3][k - 1] = true;
			}
		}
		String[] mark = { "S", "H", "C", "D" };
		for (int i = 0; i < 4; i++) {
			for (int j = 0; j < 13; j++) {
				if (!is[i][j]) {
					System.out.println(mark[i] + " " + (j + 1));
				}
			}
		}
	} main {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		String str = br.readLine();
		Boolean[][] is = new Boolean[4][13];
		for (int i = 0; i < 4; i++) {
			for (int j = 0; j < 13; j++) {
				is[i][j] = false;
			}
		}
		int n = Integer.parseInt(str);
		for (int i = 0; i < n; i++) {
			str = br.readLine();
			String[] card = str.split(" ");
			if (card[0].equals("S")) {
				int k = Integer.parseInt(card[1]);
				is[0][k - 1] = true;
			} else if (card[0].equals("H")) {
				int k = Integer.parseInt(card[1]);
				is[1][k - 1] = true;
			} else if (card[0].equals("C")) {
				int k = Integer.parseInt(card[1]);
				is[2][k - 1] = true;
			} else {
				int k = Integer.parseInt(card[1]);
				is[3][k - 1] = true;
			}
		}
		String[] mark = { "S", "H", "C", "D" };
		for (int i = 0; i < 4; i++) {
			for (int j = 0; j < 13; j++) {
				if (!is[i][j]) {
					System.out.println(mark[i] + " " + (j + 1));
				}
			}
		}
	} BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) String str = br.readLine(); str br.readLine() br.readLine br Boolean[][] is = new Boolean[4][13]; is new Boolean[4][13] 4 13 for (int i = 0; i < 4; i++) {
			for (int j = 0; j < 13; j++) {
				is[i][j] = false;
			}
		} int i = 0; int i = 0; i 0 i < 4 i 4 i++ i++ i {
			for (int j = 0; j < 13; j++) {
				is[i][j] = false;
			}
		} {
			for (int j = 0; j < 13; j++) {
				is[i][j] = false;
			}
		} for (int j = 0; j < 13; j++) {
				is[i][j] = false;
			} int j = 0; int j = 0; j 0 j < 13 j 13 j++ j++ j {
				is[i][j] = false;
			} {
				is[i][j] = false;
			} is[i][j] = false is[i][j] is[i] is i j false int n = Integer.parseInt(str); n Integer.parseInt(str) Integer.parseInt Integer str for (int i = 0; i < n; i++) {
			str = br.readLine();
			String[] card = str.split(" ");
			if (card[0].equals("S")) {
				int k = Integer.parseInt(card[1]);
				is[0][k - 1] = true;
			} else if (card[0].equals("H")) {
				int k = Integer.parseInt(card[1]);
				is[1][k - 1] = true;
			} else if (card[0].equals("C")) {
				int k = Integer.parseInt(card[1]);
				is[2][k - 1] = true;
			} else {
				int k = Integer.parseInt(card[1]);
				is[3][k - 1] = true;
			}
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			str = br.readLine();
			String[] card = str.split(" ");
			if (card[0].equals("S")) {
				int k = Integer.parseInt(card[1]);
				is[0][k - 1] = true;
			} else if (card[0].equals("H")) {
				int k = Integer.parseInt(card[1]);
				is[1][k - 1] = true;
			} else if (card[0].equals("C")) {
				int k = Integer.parseInt(card[1]);
				is[2][k - 1] = true;
			} else {
				int k = Integer.parseInt(card[1]);
				is[3][k - 1] = true;
			}
		} {
			str = br.readLine();
			String[] card = str.split(" ");
			if (card[0].equals("S")) {
				int k = Integer.parseInt(card[1]);
				is[0][k - 1] = true;
			} else if (card[0].equals("H")) {
				int k = Integer.parseInt(card[1]);
				is[1][k - 1] = true;
			} else if (card[0].equals("C")) {
				int k = Integer.parseInt(card[1]);
				is[2][k - 1] = true;
			} else {
				int k = Integer.parseInt(card[1]);
				is[3][k - 1] = true;
			}
		} str = br.readLine() str br.readLine() br.readLine br String[] card = str.split(" "); card str.split(" ") str.split str " " if (card[0].equals("S")) {
				int k = Integer.parseInt(card[1]);
				is[0][k - 1] = true;
			} else if (card[0].equals("H")) {
				int k = Integer.parseInt(card[1]);
				is[1][k - 1] = true;
			} else if (card[0].equals("C")) {
				int k = Integer.parseInt(card[1]);
				is[2][k - 1] = true;
			} else {
				int k = Integer.parseInt(card[1]);
				is[3][k - 1] = true;
			} card[0].equals("S") card[0].equals card[0] card 0 "S" {
				int k = Integer.parseInt(card[1]);
				is[0][k - 1] = true;
			} int k = Integer.parseInt(card[1]); k Integer.parseInt(card[1]) Integer.parseInt Integer card[1] card 1 is[0][k - 1] = true is[0][k - 1] is[0] is 0 k - 1 k 1 true if (card[0].equals("H")) {
				int k = Integer.parseInt(card[1]);
				is[1][k - 1] = true;
			} else if (card[0].equals("C")) {
				int k = Integer.parseInt(card[1]);
				is[2][k - 1] = true;
			} else {
				int k = Integer.parseInt(card[1]);
				is[3][k - 1] = true;
			} card[0].equals("H") card[0].equals card[0] card 0 "H" {
				int k = Integer.parseInt(card[1]);
				is[1][k - 1] = true;
			} int k = Integer.parseInt(card[1]); k Integer.parseInt(card[1]) Integer.parseInt Integer card[1] card 1 is[1][k - 1] = true is[1][k - 1] is[1] is 1 k - 1 k 1 true if (card[0].equals("C")) {
				int k = Integer.parseInt(card[1]);
				is[2][k - 1] = true;
			} else {
				int k = Integer.parseInt(card[1]);
				is[3][k - 1] = true;
			} card[0].equals("C") card[0].equals card[0] card 0 "C" {
				int k = Integer.parseInt(card[1]);
				is[2][k - 1] = true;
			} int k = Integer.parseInt(card[1]); k Integer.parseInt(card[1]) Integer.parseInt Integer card[1] card 1 is[2][k - 1] = true is[2][k - 1] is[2] is 2 k - 1 k 1 true {
				int k = Integer.parseInt(card[1]);
				is[3][k - 1] = true;
			} int k = Integer.parseInt(card[1]); k Integer.parseInt(card[1]) Integer.parseInt Integer card[1] card 1 is[3][k - 1] = true is[3][k - 1] is[3] is 3 k - 1 k 1 true String[] mark = { "S", "H", "C", "D" }; mark { "S", "H", "C", "D" } "S" "H" "C" "D" for (int i = 0; i < 4; i++) {
			for (int j = 0; j < 13; j++) {
				if (!is[i][j]) {
					System.out.println(mark[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 (!is[i][j]) {
					System.out.println(mark[i] + " " + (j + 1));
				}
			}
		} {
			for (int j = 0; j < 13; j++) {
				if (!is[i][j]) {
					System.out.println(mark[i] + " " + (j + 1));
				}
			}
		} for (int j = 0; j < 13; j++) {
				if (!is[i][j]) {
					System.out.println(mark[i] + " " + (j + 1));
				}
			} int j = 0; int j = 0; j 0 j < 13 j 13 j++ j++ j {
				if (!is[i][j]) {
					System.out.println(mark[i] + " " + (j + 1));
				}
			} {
				if (!is[i][j]) {
					System.out.println(mark[i] + " " + (j + 1));
				}
			} if (!is[i][j]) {
					System.out.println(mark[i] + " " + (j + 1));
				} !is[i][j] is[i][j] is[i] is i j {
					System.out.println(mark[i] + " " + (j + 1));
				} System.out.println(mark[i] + " " + (j + 1)) System.out.println System.out System System.out mark[i] + " " + (j + 1) mark[i] + " " + (j + 1) mark[i] mark i " " (j + 1) j 1 String[] args args public class Main {
	public static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		String str = br.readLine();
		Boolean[][] is = new Boolean[4][13];
		for (int i = 0; i < 4; i++) {
			for (int j = 0; j < 13; j++) {
				is[i][j] = false;
			}
		}
		int n = Integer.parseInt(str);
		for (int i = 0; i < n; i++) {
			str = br.readLine();
			String[] card = str.split(" ");
			if (card[0].equals("S")) {
				int k = Integer.parseInt(card[1]);
				is[0][k - 1] = true;
			} else if (card[0].equals("H")) {
				int k = Integer.parseInt(card[1]);
				is[1][k - 1] = true;
			} else if (card[0].equals("C")) {
				int k = Integer.parseInt(card[1]);
				is[2][k - 1] = true;
			} else {
				int k = Integer.parseInt(card[1]);
				is[3][k - 1] = true;
			}
		}
		String[] mark = { "S", "H", "C", "D" };
		for (int i = 0; i < 4; i++) {
			for (int j = 0; j < 13; j++) {
				if (!is[i][j]) {
					System.out.println(mark[i] + " " + (j + 1));
				}
			}
		}
	}
} public class Main {
	public static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		String str = br.readLine();
		Boolean[][] is = new Boolean[4][13];
		for (int i = 0; i < 4; i++) {
			for (int j = 0; j < 13; j++) {
				is[i][j] = false;
			}
		}
		int n = Integer.parseInt(str);
		for (int i = 0; i < n; i++) {
			str = br.readLine();
			String[] card = str.split(" ");
			if (card[0].equals("S")) {
				int k = Integer.parseInt(card[1]);
				is[0][k - 1] = true;
			} else if (card[0].equals("H")) {
				int k = Integer.parseInt(card[1]);
				is[1][k - 1] = true;
			} else if (card[0].equals("C")) {
				int k = Integer.parseInt(card[1]);
				is[2][k - 1] = true;
			} else {
				int k = Integer.parseInt(card[1]);
				is[3][k - 1] = true;
			}
		}
		String[] mark = { "S", "H", "C", "D" };
		for (int i = 0; i < 4; i++) {
			for (int j = 0; j < 13; j++) {
				if (!is[i][j]) {
					System.out.println(mark[i] + " " + (j + 1));
				}
			}
		}
	}
} Main
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class Main {
	public static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		String str = br.readLine();
		Boolean[][] is = new Boolean[4][13];
		for (int i = 0; i < 4; i++) {
			for (int j = 0; j < 13; j++) {
				is[i][j] = false;
			}
		}
		int n = Integer.parseInt(str);
		for (int i = 0; i < n; i++) {
			str = br.readLine();
			String[] card = str.split(" ");
			if (card[0].equals("S")) {
				int k = Integer.parseInt(card[1]);
				is[0][k - 1] = true;
			} else if (card[0].equals("H")) {
				int k = Integer.parseInt(card[1]);
				is[1][k - 1] = true;
			} else if (card[0].equals("C")) {
				int k = Integer.parseInt(card[1]);
				is[2][k - 1] = true;
			} else {
				int k = Integer.parseInt(card[1]);
				is[3][k - 1] = true;
			}
		}
		String[] mark = { "S", "H", "C", "D" };
		for (int i = 0; i < 4; i++) {
			for (int j = 0; j < 13; j++) {
				if (!is[i][j]) {
					System.out.println(mark[i] + " " + (j + 1));
				}
			}
		}
	}
}