import java.io.*;
import java.util.*;

public class Main {
	public static void main(String[] args) throws Exception {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		int n = Integer.parseInt(br.readLine());
		int[] s = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		int[] h = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		int[] c = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		int[] d = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		for (int i = 0; i < n; i++) {
			String[] card = br.readLine().split(" ");
			switch (card[0]) {
				case "S":
					change(Integer.parseInt(card[1]), s);
					break;
				case "H":
					change(Integer.parseInt(card[1]), h);
					break;
				case "C":
					change(Integer.parseInt(card[1]), c);
					break;
				case "D":
					change(Integer.parseInt(card[1]), d);
					break;
			}
		}
		print("S", s);
		print("H", h);
		print("C", c);
		print("D", d);
	}

	private static void print(String str, int[] array) {
		for (int i = 0; i < array.length; i++) {
			if (array[i] == 0) {
				System.out.println(str + " " + (i + 1));
			}
		}
	}

	private static void change(int n, int[] array) {
		array[n - 1] = 1;
	}
} import java.io.*; io.* java import java.util.*; util.* java public class Main {
	public static void main(String[] args) throws Exception {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		int n = Integer.parseInt(br.readLine());
		int[] s = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		int[] h = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		int[] c = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		int[] d = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		for (int i = 0; i < n; i++) {
			String[] card = br.readLine().split(" ");
			switch (card[0]) {
				case "S":
					change(Integer.parseInt(card[1]), s);
					break;
				case "H":
					change(Integer.parseInt(card[1]), h);
					break;
				case "C":
					change(Integer.parseInt(card[1]), c);
					break;
				case "D":
					change(Integer.parseInt(card[1]), d);
					break;
			}
		}
		print("S", s);
		print("H", h);
		print("C", c);
		print("D", d);
	}

	private static void print(String str, int[] array) {
		for (int i = 0; i < array.length; i++) {
			if (array[i] == 0) {
				System.out.println(str + " " + (i + 1));
			}
		}
	}

	private static void change(int n, int[] array) {
		array[n - 1] = 1;
	}
} Main public static void main(String[] args) throws Exception {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		int n = Integer.parseInt(br.readLine());
		int[] s = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		int[] h = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		int[] c = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		int[] d = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		for (int i = 0; i < n; i++) {
			String[] card = br.readLine().split(" ");
			switch (card[0]) {
				case "S":
					change(Integer.parseInt(card[1]), s);
					break;
				case "H":
					change(Integer.parseInt(card[1]), h);
					break;
				case "C":
					change(Integer.parseInt(card[1]), c);
					break;
				case "D":
					change(Integer.parseInt(card[1]), d);
					break;
			}
		}
		print("S", s);
		print("H", h);
		print("C", c);
		print("D", d);
	} main {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		int n = Integer.parseInt(br.readLine());
		int[] s = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		int[] h = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		int[] c = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		int[] d = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		for (int i = 0; i < n; i++) {
			String[] card = br.readLine().split(" ");
			switch (card[0]) {
				case "S":
					change(Integer.parseInt(card[1]), s);
					break;
				case "H":
					change(Integer.parseInt(card[1]), h);
					break;
				case "C":
					change(Integer.parseInt(card[1]), c);
					break;
				case "D":
					change(Integer.parseInt(card[1]), d);
					break;
			}
		}
		print("S", s);
		print("H", h);
		print("C", c);
		print("D", d);
	} BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) int n = Integer.parseInt(br.readLine()); n Integer.parseInt(br.readLine()) Integer.parseInt Integer br.readLine() br.readLine br int[] s = {0,0,0,0,0,0,0,0,0,0,0,0,0}; s {0,0,0,0,0,0,0,0,0,0,0,0,0} 0 0 0 0 0 0 0 0 0 0 0 0 0 int[] h = {0,0,0,0,0,0,0,0,0,0,0,0,0}; h {0,0,0,0,0,0,0,0,0,0,0,0,0} 0 0 0 0 0 0 0 0 0 0 0 0 0 int[] c = {0,0,0,0,0,0,0,0,0,0,0,0,0}; c {0,0,0,0,0,0,0,0,0,0,0,0,0} 0 0 0 0 0 0 0 0 0 0 0 0 0 int[] d = {0,0,0,0,0,0,0,0,0,0,0,0,0}; d {0,0,0,0,0,0,0,0,0,0,0,0,0} 0 0 0 0 0 0 0 0 0 0 0 0 0 for (int i = 0; i < n; i++) {
			String[] card = br.readLine().split(" ");
			switch (card[0]) {
				case "S":
					change(Integer.parseInt(card[1]), s);
					break;
				case "H":
					change(Integer.parseInt(card[1]), h);
					break;
				case "C":
					change(Integer.parseInt(card[1]), c);
					break;
				case "D":
					change(Integer.parseInt(card[1]), d);
					break;
			}
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			String[] card = br.readLine().split(" ");
			switch (card[0]) {
				case "S":
					change(Integer.parseInt(card[1]), s);
					break;
				case "H":
					change(Integer.parseInt(card[1]), h);
					break;
				case "C":
					change(Integer.parseInt(card[1]), c);
					break;
				case "D":
					change(Integer.parseInt(card[1]), d);
					break;
			}
		} {
			String[] card = br.readLine().split(" ");
			switch (card[0]) {
				case "S":
					change(Integer.parseInt(card[1]), s);
					break;
				case "H":
					change(Integer.parseInt(card[1]), h);
					break;
				case "C":
					change(Integer.parseInt(card[1]), c);
					break;
				case "D":
					change(Integer.parseInt(card[1]), d);
					break;
			}
		} String[] card = br.readLine().split(" "); card br.readLine().split(" ") br.readLine().split br.readLine() br.readLine br " " switch (card[0]) {
				case "S":
					change(Integer.parseInt(card[1]), s);
					break;
				case "H":
					change(Integer.parseInt(card[1]), h);
					break;
				case "C":
					change(Integer.parseInt(card[1]), c);
					break;
				case "D":
					change(Integer.parseInt(card[1]), d);
					break;
			} card[0] card 0 case "S": "S" case "S": change(Integer.parseInt(card[1]), s) change Integer.parseInt(card[1]) Integer.parseInt Integer card[1] card 1 s break; case "H": "H" case "H": change(Integer.parseInt(card[1]), h) change Integer.parseInt(card[1]) Integer.parseInt Integer card[1] card 1 h break; case "C": "C" case "C": change(Integer.parseInt(card[1]), c) change Integer.parseInt(card[1]) Integer.parseInt Integer card[1] card 1 c break; case "D": "D" case "D": change(Integer.parseInt(card[1]), d) change Integer.parseInt(card[1]) Integer.parseInt Integer card[1] card 1 d break; print("S", s) print "S" s print("H", h) print "H" h print("C", c) print "C" c print("D", d) print "D" d String[] args args private static void print(String str, int[] array) {
		for (int i = 0; i < array.length; i++) {
			if (array[i] == 0) {
				System.out.println(str + " " + (i + 1));
			}
		}
	} print {
		for (int i = 0; i < array.length; i++) {
			if (array[i] == 0) {
				System.out.println(str + " " + (i + 1));
			}
		}
	} for (int i = 0; i < array.length; i++) {
			if (array[i] == 0) {
				System.out.println(str + " " + (i + 1));
			}
		} int i = 0; int i = 0; i 0 i < array.length i array.length array array.length i++ i++ i {
			if (array[i] == 0) {
				System.out.println(str + " " + (i + 1));
			}
		} {
			if (array[i] == 0) {
				System.out.println(str + " " + (i + 1));
			}
		} if (array[i] == 0) {
				System.out.println(str + " " + (i + 1));
			} array[i] == 0 array[i] array i 0 {
				System.out.println(str + " " + (i + 1));
			} System.out.println(str + " " + (i + 1)) System.out.println System.out System System.out str + " " + (i + 1) str + " " + (i + 1) str " " (i + 1) i 1 String str str int[] array array private static void change(int n, int[] array) {
		array[n - 1] = 1;
	} change {
		array[n - 1] = 1;
	} array[n - 1] = 1 array[n - 1] array n - 1 n 1 1 int n n int[] array array public class Main {
	public static void main(String[] args) throws Exception {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		int n = Integer.parseInt(br.readLine());
		int[] s = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		int[] h = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		int[] c = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		int[] d = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		for (int i = 0; i < n; i++) {
			String[] card = br.readLine().split(" ");
			switch (card[0]) {
				case "S":
					change(Integer.parseInt(card[1]), s);
					break;
				case "H":
					change(Integer.parseInt(card[1]), h);
					break;
				case "C":
					change(Integer.parseInt(card[1]), c);
					break;
				case "D":
					change(Integer.parseInt(card[1]), d);
					break;
			}
		}
		print("S", s);
		print("H", h);
		print("C", c);
		print("D", d);
	}

	private static void print(String str, int[] array) {
		for (int i = 0; i < array.length; i++) {
			if (array[i] == 0) {
				System.out.println(str + " " + (i + 1));
			}
		}
	}

	private static void change(int n, int[] array) {
		array[n - 1] = 1;
	}
} public class Main {
	public static void main(String[] args) throws Exception {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		int n = Integer.parseInt(br.readLine());
		int[] s = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		int[] h = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		int[] c = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		int[] d = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		for (int i = 0; i < n; i++) {
			String[] card = br.readLine().split(" ");
			switch (card[0]) {
				case "S":
					change(Integer.parseInt(card[1]), s);
					break;
				case "H":
					change(Integer.parseInt(card[1]), h);
					break;
				case "C":
					change(Integer.parseInt(card[1]), c);
					break;
				case "D":
					change(Integer.parseInt(card[1]), d);
					break;
			}
		}
		print("S", s);
		print("H", h);
		print("C", c);
		print("D", d);
	}

	private static void print(String str, int[] array) {
		for (int i = 0; i < array.length; i++) {
			if (array[i] == 0) {
				System.out.println(str + " " + (i + 1));
			}
		}
	}

	private static void change(int n, int[] array) {
		array[n - 1] = 1;
	}
} Main
import java.io.*;
import java.util.*;

public class Main {
	public static void main(String[] args) throws Exception {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		int n = Integer.parseInt(br.readLine());
		int[] s = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		int[] h = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		int[] c = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		int[] d = {0,0,0,0,0,0,0,0,0,0,0,0,0};
		for (int i = 0; i < n; i++) {
			String[] card = br.readLine().split(" ");
			switch (card[0]) {
				case "S":
					change(Integer.parseInt(card[1]), s);
					break;
				case "H":
					change(Integer.parseInt(card[1]), h);
					break;
				case "C":
					change(Integer.parseInt(card[1]), c);
					break;
				case "D":
					change(Integer.parseInt(card[1]), d);
					break;
			}
		}
		print("S", s);
		print("H", h);
		print("C", c);
		print("D", d);
	}

	private static void print(String str, int[] array) {
		for (int i = 0; i < array.length; i++) {
			if (array[i] == 0) {
				System.out.println(str + " " + (i + 1));
			}
		}
	}

	private static void change(int n, int[] array) {
		array[n - 1] = 1;
	}
}