import java.util.Scanner;

public class Main{

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int s[] = new int[13];
		int h[] = new int[13];
		int c[] = new int[13];
		int d[] = new int[13];
		for(int i=0;i<n;i++){
			String t = sc.next();
			if(t.equals("S")){
				int j = sc.nextInt();
				s[j-1]++;
			}else if(t.equals("H")){
				int j = sc.nextInt();
				h[j-1]++;
			}else if(t.equals("C")){
				int j = sc.nextInt();
				c[j-1]++;
			}else{
				int j = sc.nextInt();
				d[j-1]++;
			}
		}
		for(int i=0;i<13;i++){
			if(s[i]==0){
				int t = i+1;
				System.out.println("S "+t);
			}
		}
		for(int i=0;i<13;i++){
			if(h[i]==0){
				int t = i+1;
				System.out.println("H "+t);
			}
		}
		for(int i=0;i<13;i++){
			if(c[i]==0){
				int t = i+1;
				System.out.println("C "+t);
			}
		}
		for(int i=0;i<13;i++){
			if(d[i]==0){
				int t = i+1;
				System.out.println("D "+t);
			}
		}
	}

} import java.util.Scanner; Scanner java.util public class Main{

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int s[] = new int[13];
		int h[] = new int[13];
		int c[] = new int[13];
		int d[] = new int[13];
		for(int i=0;i<n;i++){
			String t = sc.next();
			if(t.equals("S")){
				int j = sc.nextInt();
				s[j-1]++;
			}else if(t.equals("H")){
				int j = sc.nextInt();
				h[j-1]++;
			}else if(t.equals("C")){
				int j = sc.nextInt();
				c[j-1]++;
			}else{
				int j = sc.nextInt();
				d[j-1]++;
			}
		}
		for(int i=0;i<13;i++){
			if(s[i]==0){
				int t = i+1;
				System.out.println("S "+t);
			}
		}
		for(int i=0;i<13;i++){
			if(h[i]==0){
				int t = i+1;
				System.out.println("H "+t);
			}
		}
		for(int i=0;i<13;i++){
			if(c[i]==0){
				int t = i+1;
				System.out.println("C "+t);
			}
		}
		for(int i=0;i<13;i++){
			if(d[i]==0){
				int t = i+1;
				System.out.println("D "+t);
			}
		}
	}

} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int s[] = new int[13];
		int h[] = new int[13];
		int c[] = new int[13];
		int d[] = new int[13];
		for(int i=0;i<n;i++){
			String t = sc.next();
			if(t.equals("S")){
				int j = sc.nextInt();
				s[j-1]++;
			}else if(t.equals("H")){
				int j = sc.nextInt();
				h[j-1]++;
			}else if(t.equals("C")){
				int j = sc.nextInt();
				c[j-1]++;
			}else{
				int j = sc.nextInt();
				d[j-1]++;
			}
		}
		for(int i=0;i<13;i++){
			if(s[i]==0){
				int t = i+1;
				System.out.println("S "+t);
			}
		}
		for(int i=0;i<13;i++){
			if(h[i]==0){
				int t = i+1;
				System.out.println("H "+t);
			}
		}
		for(int i=0;i<13;i++){
			if(c[i]==0){
				int t = i+1;
				System.out.println("C "+t);
			}
		}
		for(int i=0;i<13;i++){
			if(d[i]==0){
				int t = i+1;
				System.out.println("D "+t);
			}
		}
	} main {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int s[] = new int[13];
		int h[] = new int[13];
		int c[] = new int[13];
		int d[] = new int[13];
		for(int i=0;i<n;i++){
			String t = sc.next();
			if(t.equals("S")){
				int j = sc.nextInt();
				s[j-1]++;
			}else if(t.equals("H")){
				int j = sc.nextInt();
				h[j-1]++;
			}else if(t.equals("C")){
				int j = sc.nextInt();
				c[j-1]++;
			}else{
				int j = sc.nextInt();
				d[j-1]++;
			}
		}
		for(int i=0;i<13;i++){
			if(s[i]==0){
				int t = i+1;
				System.out.println("S "+t);
			}
		}
		for(int i=0;i<13;i++){
			if(h[i]==0){
				int t = i+1;
				System.out.println("H "+t);
			}
		}
		for(int i=0;i<13;i++){
			if(c[i]==0){
				int t = i+1;
				System.out.println("C "+t);
			}
		}
		for(int i=0;i<13;i++){
			if(d[i]==0){
				int t = i+1;
				System.out.println("D "+t);
			}
		}
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc int s[] = new int[13]; s new int[13] 13 int h[] = new int[13]; h new int[13] 13 int c[] = new int[13]; c new int[13] 13 int d[] = new int[13]; d new int[13] 13 for(int i=0;i<n;i++){
			String t = sc.next();
			if(t.equals("S")){
				int j = sc.nextInt();
				s[j-1]++;
			}else if(t.equals("H")){
				int j = sc.nextInt();
				h[j-1]++;
			}else if(t.equals("C")){
				int j = sc.nextInt();
				c[j-1]++;
			}else{
				int j = sc.nextInt();
				d[j-1]++;
			}
		} int i=0; int i=0; i 0 i<n i n i++ i++ i {
			String t = sc.next();
			if(t.equals("S")){
				int j = sc.nextInt();
				s[j-1]++;
			}else if(t.equals("H")){
				int j = sc.nextInt();
				h[j-1]++;
			}else if(t.equals("C")){
				int j = sc.nextInt();
				c[j-1]++;
			}else{
				int j = sc.nextInt();
				d[j-1]++;
			}
		} {
			String t = sc.next();
			if(t.equals("S")){
				int j = sc.nextInt();
				s[j-1]++;
			}else if(t.equals("H")){
				int j = sc.nextInt();
				h[j-1]++;
			}else if(t.equals("C")){
				int j = sc.nextInt();
				c[j-1]++;
			}else{
				int j = sc.nextInt();
				d[j-1]++;
			}
		} String t = sc.next(); t sc.next() sc.next sc if(t.equals("S")){
				int j = sc.nextInt();
				s[j-1]++;
			}else if(t.equals("H")){
				int j = sc.nextInt();
				h[j-1]++;
			}else if(t.equals("C")){
				int j = sc.nextInt();
				c[j-1]++;
			}else{
				int j = sc.nextInt();
				d[j-1]++;
			} t.equals("S") t.equals t "S" {
				int j = sc.nextInt();
				s[j-1]++;
			} int j = sc.nextInt(); j sc.nextInt() sc.nextInt sc s[j-1]++ s[j-1] s j-1 j 1 if(t.equals("H")){
				int j = sc.nextInt();
				h[j-1]++;
			}else if(t.equals("C")){
				int j = sc.nextInt();
				c[j-1]++;
			}else{
				int j = sc.nextInt();
				d[j-1]++;
			} t.equals("H") t.equals t "H" {
				int j = sc.nextInt();
				h[j-1]++;
			} int j = sc.nextInt(); j sc.nextInt() sc.nextInt sc h[j-1]++ h[j-1] h j-1 j 1 if(t.equals("C")){
				int j = sc.nextInt();
				c[j-1]++;
			}else{
				int j = sc.nextInt();
				d[j-1]++;
			} t.equals("C") t.equals t "C" {
				int j = sc.nextInt();
				c[j-1]++;
			} int j = sc.nextInt(); j sc.nextInt() sc.nextInt sc c[j-1]++ c[j-1] c j-1 j 1 {
				int j = sc.nextInt();
				d[j-1]++;
			} int j = sc.nextInt(); j sc.nextInt() sc.nextInt sc d[j-1]++ d[j-1] d j-1 j 1 for(int i=0;i<13;i++){
			if(s[i]==0){
				int t = i+1;
				System.out.println("S "+t);
			}
		} int i=0; int i=0; i 0 i<13 i 13 i++ i++ i {
			if(s[i]==0){
				int t = i+1;
				System.out.println("S "+t);
			}
		} {
			if(s[i]==0){
				int t = i+1;
				System.out.println("S "+t);
			}
		} if(s[i]==0){
				int t = i+1;
				System.out.println("S "+t);
			} s[i]==0 s[i] s i 0 {
				int t = i+1;
				System.out.println("S "+t);
			} int t = i+1; t i+1 i 1 System.out.println("S "+t) System.out.println System.out System System.out "S "+t "S " t for(int i=0;i<13;i++){
			if(h[i]==0){
				int t = i+1;
				System.out.println("H "+t);
			}
		} int i=0; int i=0; i 0 i<13 i 13 i++ i++ i {
			if(h[i]==0){
				int t = i+1;
				System.out.println("H "+t);
			}
		} {
			if(h[i]==0){
				int t = i+1;
				System.out.println("H "+t);
			}
		} if(h[i]==0){
				int t = i+1;
				System.out.println("H "+t);
			} h[i]==0 h[i] h i 0 {
				int t = i+1;
				System.out.println("H "+t);
			} int t = i+1; t i+1 i 1 System.out.println("H "+t) System.out.println System.out System System.out "H "+t "H " t for(int i=0;i<13;i++){
			if(c[i]==0){
				int t = i+1;
				System.out.println("C "+t);
			}
		} int i=0; int i=0; i 0 i<13 i 13 i++ i++ i {
			if(c[i]==0){
				int t = i+1;
				System.out.println("C "+t);
			}
		} {
			if(c[i]==0){
				int t = i+1;
				System.out.println("C "+t);
			}
		} if(c[i]==0){
				int t = i+1;
				System.out.println("C "+t);
			} c[i]==0 c[i] c i 0 {
				int t = i+1;
				System.out.println("C "+t);
			} int t = i+1; t i+1 i 1 System.out.println("C "+t) System.out.println System.out System System.out "C "+t "C " t for(int i=0;i<13;i++){
			if(d[i]==0){
				int t = i+1;
				System.out.println("D "+t);
			}
		} int i=0; int i=0; i 0 i<13 i 13 i++ i++ i {
			if(d[i]==0){
				int t = i+1;
				System.out.println("D "+t);
			}
		} {
			if(d[i]==0){
				int t = i+1;
				System.out.println("D "+t);
			}
		} if(d[i]==0){
				int t = i+1;
				System.out.println("D "+t);
			} d[i]==0 d[i] d i 0 {
				int t = i+1;
				System.out.println("D "+t);
			} int t = i+1; t i+1 i 1 System.out.println("D "+t) System.out.println System.out System System.out "D "+t "D " t String[] args args public class Main{

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int s[] = new int[13];
		int h[] = new int[13];
		int c[] = new int[13];
		int d[] = new int[13];
		for(int i=0;i<n;i++){
			String t = sc.next();
			if(t.equals("S")){
				int j = sc.nextInt();
				s[j-1]++;
			}else if(t.equals("H")){
				int j = sc.nextInt();
				h[j-1]++;
			}else if(t.equals("C")){
				int j = sc.nextInt();
				c[j-1]++;
			}else{
				int j = sc.nextInt();
				d[j-1]++;
			}
		}
		for(int i=0;i<13;i++){
			if(s[i]==0){
				int t = i+1;
				System.out.println("S "+t);
			}
		}
		for(int i=0;i<13;i++){
			if(h[i]==0){
				int t = i+1;
				System.out.println("H "+t);
			}
		}
		for(int i=0;i<13;i++){
			if(c[i]==0){
				int t = i+1;
				System.out.println("C "+t);
			}
		}
		for(int i=0;i<13;i++){
			if(d[i]==0){
				int t = i+1;
				System.out.println("D "+t);
			}
		}
	}

} public class Main{

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int s[] = new int[13];
		int h[] = new int[13];
		int c[] = new int[13];
		int d[] = new int[13];
		for(int i=0;i<n;i++){
			String t = sc.next();
			if(t.equals("S")){
				int j = sc.nextInt();
				s[j-1]++;
			}else if(t.equals("H")){
				int j = sc.nextInt();
				h[j-1]++;
			}else if(t.equals("C")){
				int j = sc.nextInt();
				c[j-1]++;
			}else{
				int j = sc.nextInt();
				d[j-1]++;
			}
		}
		for(int i=0;i<13;i++){
			if(s[i]==0){
				int t = i+1;
				System.out.println("S "+t);
			}
		}
		for(int i=0;i<13;i++){
			if(h[i]==0){
				int t = i+1;
				System.out.println("H "+t);
			}
		}
		for(int i=0;i<13;i++){
			if(c[i]==0){
				int t = i+1;
				System.out.println("C "+t);
			}
		}
		for(int i=0;i<13;i++){
			if(d[i]==0){
				int t = i+1;
				System.out.println("D "+t);
			}
		}
	}

} Main
import java.util.Scanner;

public class Main{

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int s[] = new int[13];
		int h[] = new int[13];
		int c[] = new int[13];
		int d[] = new int[13];
		for(int i=0;i<n;i++){
			String t = sc.next();
			if(t.equals("S")){
				int j = sc.nextInt();
				s[j-1]++;
			}else if(t.equals("H")){
				int j = sc.nextInt();
				h[j-1]++;
			}else if(t.equals("C")){
				int j = sc.nextInt();
				c[j-1]++;
			}else{
				int j = sc.nextInt();
				d[j-1]++;
			}
		}
		for(int i=0;i<13;i++){
			if(s[i]==0){
				int t = i+1;
				System.out.println("S "+t);
			}
		}
		for(int i=0;i<13;i++){
			if(h[i]==0){
				int t = i+1;
				System.out.println("H "+t);
			}
		}
		for(int i=0;i<13;i++){
			if(c[i]==0){
				int t = i+1;
				System.out.println("C "+t);
			}
		}
		for(int i=0;i<13;i++){
			if(d[i]==0){
				int t = i+1;
				System.out.println("D "+t);
			}
		}
	}

}