import java.io.*;
import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;

public class Main {
	public static void main(String args[]) throws IOException {

		@SuppressWarnings("resource")
		Scanner sc = new Scanner(System.in);

		// ??¨???????????£????????????????????????????????????
		List<String> all = new ArrayList<String>();
		for (char c : "SHCD".toCharArray()) {
			for (int i = 1; i <= 13; i++) {
				all.add(String.format("%c %d", c, i));
			}
		}
		
		// ?????£???????????????????????????????????????
		int count = sc.nextInt();
		sc.nextLine();
		for (int i = 0; i < count; i++) {
			all.remove(sc.nextLine());
		}
		
		// ?????£??????????????????
		for (String s : all) {
			System.out.println(s);
		}
	}
} import java.io.*; io.* java import java.util.ArrayList; ArrayList java.util import java.util.List; List java.util import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String args[]) throws IOException {

		@SuppressWarnings("resource")
		Scanner sc = new Scanner(System.in);

		// ??¨???????????£????????????????????????????????????
		List<String> all = new ArrayList<String>();
		for (char c : "SHCD".toCharArray()) {
			for (int i = 1; i <= 13; i++) {
				all.add(String.format("%c %d", c, i));
			}
		}
		
		// ?????£???????????????????????????????????????
		int count = sc.nextInt();
		sc.nextLine();
		for (int i = 0; i < count; i++) {
			all.remove(sc.nextLine());
		}
		
		// ?????£??????????????????
		for (String s : all) {
			System.out.println(s);
		}
	}
} Main public static void main(String args[]) throws IOException {

		@SuppressWarnings("resource")
		Scanner sc = new Scanner(System.in);

		// ??¨???????????£????????????????????????????????????
		List<String> all = new ArrayList<String>();
		for (char c : "SHCD".toCharArray()) {
			for (int i = 1; i <= 13; i++) {
				all.add(String.format("%c %d", c, i));
			}
		}
		
		// ?????£???????????????????????????????????????
		int count = sc.nextInt();
		sc.nextLine();
		for (int i = 0; i < count; i++) {
			all.remove(sc.nextLine());
		}
		
		// ?????£??????????????????
		for (String s : all) {
			System.out.println(s);
		}
	} main {

		@SuppressWarnings("resource")
		Scanner sc = new Scanner(System.in);

		// ??¨???????????£????????????????????????????????????
		List<String> all = new ArrayList<String>();
		for (char c : "SHCD".toCharArray()) {
			for (int i = 1; i <= 13; i++) {
				all.add(String.format("%c %d", c, i));
			}
		}
		
		// ?????£???????????????????????????????????????
		int count = sc.nextInt();
		sc.nextLine();
		for (int i = 0; i < count; i++) {
			all.remove(sc.nextLine());
		}
		
		// ?????£??????????????????
		for (String s : all) {
			System.out.println(s);
		}
	} @SuppressWarnings("resource")
		Scanner sc = new Scanner(System.in); sc new Scanner(System.in) List<String> all = new ArrayList<String>(); all new ArrayList<String>() for (char c : "SHCD".toCharArray()) {
			for (int i = 1; i <= 13; i++) {
				all.add(String.format("%c %d", c, i));
			}
		} char c "SHCD".toCharArray() "SHCD".toCharArray "SHCD" {
			for (int i = 1; i <= 13; i++) {
				all.add(String.format("%c %d", c, i));
			}
		} {
			for (int i = 1; i <= 13; i++) {
				all.add(String.format("%c %d", c, i));
			}
		} for (int i = 1; i <= 13; i++) {
				all.add(String.format("%c %d", c, i));
			} int i = 1; int i = 1; i 1 i <= 13 i 13 i++ i++ i {
				all.add(String.format("%c %d", c, i));
			} {
				all.add(String.format("%c %d", c, i));
			} all.add(String.format("%c %d", c, i)) all.add all String.format("%c %d", c, i) String.format String "%c %d" c i int count = sc.nextInt(); count sc.nextInt() sc.nextInt sc sc.nextLine() sc.nextLine sc for (int i = 0; i < count; i++) {
			all.remove(sc.nextLine());
		} int i = 0; int i = 0; i 0 i < count i count i++ i++ i {
			all.remove(sc.nextLine());
		} {
			all.remove(sc.nextLine());
		} all.remove(sc.nextLine()) all.remove all sc.nextLine() sc.nextLine sc for (String s : all) {
			System.out.println(s);
		} String s all {
			System.out.println(s);
		} {
			System.out.println(s);
		} System.out.println(s) System.out.println System.out System System.out s String args[] args public class Main {
	public static void main(String args[]) throws IOException {

		@SuppressWarnings("resource")
		Scanner sc = new Scanner(System.in);

		// ??¨???????????£????????????????????????????????????
		List<String> all = new ArrayList<String>();
		for (char c : "SHCD".toCharArray()) {
			for (int i = 1; i <= 13; i++) {
				all.add(String.format("%c %d", c, i));
			}
		}
		
		// ?????£???????????????????????????????????????
		int count = sc.nextInt();
		sc.nextLine();
		for (int i = 0; i < count; i++) {
			all.remove(sc.nextLine());
		}
		
		// ?????£??????????????????
		for (String s : all) {
			System.out.println(s);
		}
	}
} public class Main {
	public static void main(String args[]) throws IOException {

		@SuppressWarnings("resource")
		Scanner sc = new Scanner(System.in);

		// ??¨???????????£????????????????????????????????????
		List<String> all = new ArrayList<String>();
		for (char c : "SHCD".toCharArray()) {
			for (int i = 1; i <= 13; i++) {
				all.add(String.format("%c %d", c, i));
			}
		}
		
		// ?????£???????????????????????????????????????
		int count = sc.nextInt();
		sc.nextLine();
		for (int i = 0; i < count; i++) {
			all.remove(sc.nextLine());
		}
		
		// ?????£??????????????????
		for (String s : all) {
			System.out.println(s);
		}
	}
} Main
import java.io.*;
import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;

public class Main {
	public static void main(String args[]) throws IOException {

		@SuppressWarnings("resource")
		Scanner sc = new Scanner(System.in);

		// ??¨???????????£????????????????????????????????????
		List<String> all = new ArrayList<String>();
		for (char c : "SHCD".toCharArray()) {
			for (int i = 1; i <= 13; i++) {
				all.add(String.format("%c %d", c, i));
			}
		}
		
		// ?????£???????????????????????????????????????
		int count = sc.nextInt();
		sc.nextLine();
		for (int i = 0; i < count; i++) {
			all.remove(sc.nextLine());
		}
		
		// ?????£??????????????????
		for (String s : all) {
			System.out.println(s);
		}
	}
}