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

public class Main {

	public static void main(String[] args) {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));

		// ?????????
		final char[] mark = {'S','H','C','D'};
		String[][] cards = new String[4][13];

		try {
			// ????????????????????°?????\???
			int cardNum = Integer.parseInt(br.readLine());

			// ????????????????????\???
			String str;
			for(int i=0;i<cardNum;i++){
				str = br.readLine();
				for(int j=0;j<mark.length;j++){
					if(str.charAt(0) == mark[j]){
						// ??°???????????£?????????????????????
						cards[j][Integer.parseInt(str.substring(2,str.length()))-1] = "";
						break;
					}
				}
			}

			// ?????£?????????????????????????????\
			StringBuilder sb = new StringBuilder();
			for(int i=0;i<mark.length;i++){
				for(int j=0;j<cards[i].length;j++){
					if(cards[i][j] == null)
						sb.append(mark[i]).append(" ").append((j+1)).append("\n");
				}
			}

			// ??????
			System.out.print(sb.toString());

		} catch (IOException e) {
			e.printStackTrace();
		}finally{
			try{
				if(br != null){
					br.close();
				}
			}catch(IOException ioe){
			}

		}
	}
} 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) {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));

		// ?????????
		final char[] mark = {'S','H','C','D'};
		String[][] cards = new String[4][13];

		try {
			// ????????????????????°?????\???
			int cardNum = Integer.parseInt(br.readLine());

			// ????????????????????\???
			String str;
			for(int i=0;i<cardNum;i++){
				str = br.readLine();
				for(int j=0;j<mark.length;j++){
					if(str.charAt(0) == mark[j]){
						// ??°???????????£?????????????????????
						cards[j][Integer.parseInt(str.substring(2,str.length()))-1] = "";
						break;
					}
				}
			}

			// ?????£?????????????????????????????\
			StringBuilder sb = new StringBuilder();
			for(int i=0;i<mark.length;i++){
				for(int j=0;j<cards[i].length;j++){
					if(cards[i][j] == null)
						sb.append(mark[i]).append(" ").append((j+1)).append("\n");
				}
			}

			// ??????
			System.out.print(sb.toString());

		} catch (IOException e) {
			e.printStackTrace();
		}finally{
			try{
				if(br != null){
					br.close();
				}
			}catch(IOException ioe){
			}

		}
	}
} Main public static void main(String[] args) {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));

		// ?????????
		final char[] mark = {'S','H','C','D'};
		String[][] cards = new String[4][13];

		try {
			// ????????????????????°?????\???
			int cardNum = Integer.parseInt(br.readLine());

			// ????????????????????\???
			String str;
			for(int i=0;i<cardNum;i++){
				str = br.readLine();
				for(int j=0;j<mark.length;j++){
					if(str.charAt(0) == mark[j]){
						// ??°???????????£?????????????????????
						cards[j][Integer.parseInt(str.substring(2,str.length()))-1] = "";
						break;
					}
				}
			}

			// ?????£?????????????????????????????\
			StringBuilder sb = new StringBuilder();
			for(int i=0;i<mark.length;i++){
				for(int j=0;j<cards[i].length;j++){
					if(cards[i][j] == null)
						sb.append(mark[i]).append(" ").append((j+1)).append("\n");
				}
			}

			// ??????
			System.out.print(sb.toString());

		} catch (IOException e) {
			e.printStackTrace();
		}finally{
			try{
				if(br != null){
					br.close();
				}
			}catch(IOException ioe){
			}

		}
	} main {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));

		// ?????????
		final char[] mark = {'S','H','C','D'};
		String[][] cards = new String[4][13];

		try {
			// ????????????????????°?????\???
			int cardNum = Integer.parseInt(br.readLine());

			// ????????????????????\???
			String str;
			for(int i=0;i<cardNum;i++){
				str = br.readLine();
				for(int j=0;j<mark.length;j++){
					if(str.charAt(0) == mark[j]){
						// ??°???????????£?????????????????????
						cards[j][Integer.parseInt(str.substring(2,str.length()))-1] = "";
						break;
					}
				}
			}

			// ?????£?????????????????????????????\
			StringBuilder sb = new StringBuilder();
			for(int i=0;i<mark.length;i++){
				for(int j=0;j<cards[i].length;j++){
					if(cards[i][j] == null)
						sb.append(mark[i]).append(" ").append((j+1)).append("\n");
				}
			}

			// ??????
			System.out.print(sb.toString());

		} catch (IOException e) {
			e.printStackTrace();
		}finally{
			try{
				if(br != null){
					br.close();
				}
			}catch(IOException ioe){
			}

		}
	} BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) final char[] mark = {'S','H','C','D'}; mark {'S','H','C','D'} 'S' 'H' 'C' 'D' String[][] cards = new String[4][13]; cards new String[4][13] 4 13 try {
			// ????????????????????°?????\???
			int cardNum = Integer.parseInt(br.readLine());

			// ????????????????????\???
			String str;
			for(int i=0;i<cardNum;i++){
				str = br.readLine();
				for(int j=0;j<mark.length;j++){
					if(str.charAt(0) == mark[j]){
						// ??°???????????£?????????????????????
						cards[j][Integer.parseInt(str.substring(2,str.length()))-1] = "";
						break;
					}
				}
			}

			// ?????£?????????????????????????????\
			StringBuilder sb = new StringBuilder();
			for(int i=0;i<mark.length;i++){
				for(int j=0;j<cards[i].length;j++){
					if(cards[i][j] == null)
						sb.append(mark[i]).append(" ").append((j+1)).append("\n");
				}
			}

			// ??????
			System.out.print(sb.toString());

		} catch (IOException e) {
			e.printStackTrace();
		}finally{
			try{
				if(br != null){
					br.close();
				}
			}catch(IOException ioe){
			}

		} catch (IOException e) {
			e.printStackTrace();
		} IOException e {
			e.printStackTrace();
		} e.printStackTrace() e.printStackTrace e {
			try{
				if(br != null){
					br.close();
				}
			}catch(IOException ioe){
			}

		} try{
				if(br != null){
					br.close();
				}
			}catch(IOException ioe){
			} catch(IOException ioe){
			} IOException ioe {
			} {
				if(br != null){
					br.close();
				}
			} if(br != null){
					br.close();
				} br != null br null {
					br.close();
				} br.close() br.close br {
			// ????????????????????°?????\???
			int cardNum = Integer.parseInt(br.readLine());

			// ????????????????????\???
			String str;
			for(int i=0;i<cardNum;i++){
				str = br.readLine();
				for(int j=0;j<mark.length;j++){
					if(str.charAt(0) == mark[j]){
						// ??°???????????£?????????????????????
						cards[j][Integer.parseInt(str.substring(2,str.length()))-1] = "";
						break;
					}
				}
			}

			// ?????£?????????????????????????????\
			StringBuilder sb = new StringBuilder();
			for(int i=0;i<mark.length;i++){
				for(int j=0;j<cards[i].length;j++){
					if(cards[i][j] == null)
						sb.append(mark[i]).append(" ").append((j+1)).append("\n");
				}
			}

			// ??????
			System.out.print(sb.toString());

		} int cardNum = Integer.parseInt(br.readLine()); cardNum Integer.parseInt(br.readLine()) Integer.parseInt Integer br.readLine() br.readLine br String str; str for(int i=0;i<cardNum;i++){
				str = br.readLine();
				for(int j=0;j<mark.length;j++){
					if(str.charAt(0) == mark[j]){
						// ??°???????????£?????????????????????
						cards[j][Integer.parseInt(str.substring(2,str.length()))-1] = "";
						break;
					}
				}
			} int i=0; int i=0; i 0 i<cardNum i cardNum i++ i++ i {
				str = br.readLine();
				for(int j=0;j<mark.length;j++){
					if(str.charAt(0) == mark[j]){
						// ??°???????????£?????????????????????
						cards[j][Integer.parseInt(str.substring(2,str.length()))-1] = "";
						break;
					}
				}
			} {
				str = br.readLine();
				for(int j=0;j<mark.length;j++){
					if(str.charAt(0) == mark[j]){
						// ??°???????????£?????????????????????
						cards[j][Integer.parseInt(str.substring(2,str.length()))-1] = "";
						break;
					}
				}
			} str = br.readLine() str br.readLine() br.readLine br for(int j=0;j<mark.length;j++){
					if(str.charAt(0) == mark[j]){
						// ??°???????????£?????????????????????
						cards[j][Integer.parseInt(str.substring(2,str.length()))-1] = "";
						break;
					}
				} int j=0; int j=0; j 0 j<mark.length j mark.length mark mark.length j++ j++ j {
					if(str.charAt(0) == mark[j]){
						// ??°???????????£?????????????????????
						cards[j][Integer.parseInt(str.substring(2,str.length()))-1] = "";
						break;
					}
				} {
					if(str.charAt(0) == mark[j]){
						// ??°???????????£?????????????????????
						cards[j][Integer.parseInt(str.substring(2,str.length()))-1] = "";
						break;
					}
				} if(str.charAt(0) == mark[j]){
						// ??°???????????£?????????????????????
						cards[j][Integer.parseInt(str.substring(2,str.length()))-1] = "";
						break;
					} str.charAt(0) == mark[j] str.charAt(0) str.charAt str 0 mark[j] mark j {
						// ??°???????????£?????????????????????
						cards[j][Integer.parseInt(str.substring(2,str.length()))-1] = "";
						break;
					} cards[j][Integer.parseInt(str.substring(2,str.length()))-1] = "" cards[j][Integer.parseInt(str.substring(2,str.length()))-1] cards[j] cards j Integer.parseInt(str.substring(2,str.length()))-1 Integer.parseInt(str.substring(2,str.length())) Integer.parseInt Integer str.substring(2,str.length()) str.substring str 2 str.length() str.length str 1 "" break; StringBuilder sb = new StringBuilder(); sb new StringBuilder() for(int i=0;i<mark.length;i++){
				for(int j=0;j<cards[i].length;j++){
					if(cards[i][j] == null)
						sb.append(mark[i]).append(" ").append((j+1)).append("\n");
				}
			} int i=0; int i=0; i 0 i<mark.length i mark.length mark mark.length i++ i++ i {
				for(int j=0;j<cards[i].length;j++){
					if(cards[i][j] == null)
						sb.append(mark[i]).append(" ").append((j+1)).append("\n");
				}
			} {
				for(int j=0;j<cards[i].length;j++){
					if(cards[i][j] == null)
						sb.append(mark[i]).append(" ").append((j+1)).append("\n");
				}
			} for(int j=0;j<cards[i].length;j++){
					if(cards[i][j] == null)
						sb.append(mark[i]).append(" ").append((j+1)).append("\n");
				} int j=0; int j=0; j 0 j<cards[i].length j cards[i].length cards[i] cards i cards[i].length j++ j++ j {
					if(cards[i][j] == null)
						sb.append(mark[i]).append(" ").append((j+1)).append("\n");
				} {
					if(cards[i][j] == null)
						sb.append(mark[i]).append(" ").append((j+1)).append("\n");
				} if(cards[i][j] == null)
						sb.append(mark[i]).append(" ").append((j+1)).append("\n"); cards[i][j] == null cards[i][j] cards[i] cards i j null sb.append(mark[i]).append(" ").append((j+1)).append("\n") sb.append(mark[i]).append(" ").append((j+1)).append sb.append(mark[i]).append(" ").append((j+1)) sb.append(mark[i]).append(" ").append sb.append(mark[i]).append(" ") sb.append(mark[i]).append sb.append(mark[i]) sb.append sb mark[i] mark i " " (j+1) j 1 "\n" System.out.print(sb.toString()) System.out.print System.out System System.out sb.toString() sb.toString sb String[] args args public class Main {

	public static void main(String[] args) {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));

		// ?????????
		final char[] mark = {'S','H','C','D'};
		String[][] cards = new String[4][13];

		try {
			// ????????????????????°?????\???
			int cardNum = Integer.parseInt(br.readLine());

			// ????????????????????\???
			String str;
			for(int i=0;i<cardNum;i++){
				str = br.readLine();
				for(int j=0;j<mark.length;j++){
					if(str.charAt(0) == mark[j]){
						// ??°???????????£?????????????????????
						cards[j][Integer.parseInt(str.substring(2,str.length()))-1] = "";
						break;
					}
				}
			}

			// ?????£?????????????????????????????\
			StringBuilder sb = new StringBuilder();
			for(int i=0;i<mark.length;i++){
				for(int j=0;j<cards[i].length;j++){
					if(cards[i][j] == null)
						sb.append(mark[i]).append(" ").append((j+1)).append("\n");
				}
			}

			// ??????
			System.out.print(sb.toString());

		} catch (IOException e) {
			e.printStackTrace();
		}finally{
			try{
				if(br != null){
					br.close();
				}
			}catch(IOException ioe){
			}

		}
	}
} public class Main {

	public static void main(String[] args) {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));

		// ?????????
		final char[] mark = {'S','H','C','D'};
		String[][] cards = new String[4][13];

		try {
			// ????????????????????°?????\???
			int cardNum = Integer.parseInt(br.readLine());

			// ????????????????????\???
			String str;
			for(int i=0;i<cardNum;i++){
				str = br.readLine();
				for(int j=0;j<mark.length;j++){
					if(str.charAt(0) == mark[j]){
						// ??°???????????£?????????????????????
						cards[j][Integer.parseInt(str.substring(2,str.length()))-1] = "";
						break;
					}
				}
			}

			// ?????£?????????????????????????????\
			StringBuilder sb = new StringBuilder();
			for(int i=0;i<mark.length;i++){
				for(int j=0;j<cards[i].length;j++){
					if(cards[i][j] == null)
						sb.append(mark[i]).append(" ").append((j+1)).append("\n");
				}
			}

			// ??????
			System.out.print(sb.toString());

		} catch (IOException e) {
			e.printStackTrace();
		}finally{
			try{
				if(br != null){
					br.close();
				}
			}catch(IOException ioe){
			}

		}
	}
} Main

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

public class Main {

	public static void main(String[] args) {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));

		// ?????????
		final char[] mark = {'S','H','C','D'};
		String[][] cards = new String[4][13];

		try {
			// ????????????????????°?????\???
			int cardNum = Integer.parseInt(br.readLine());

			// ????????????????????\???
			String str;
			for(int i=0;i<cardNum;i++){
				str = br.readLine();
				for(int j=0;j<mark.length;j++){
					if(str.charAt(0) == mark[j]){
						// ??°???????????£?????????????????????
						cards[j][Integer.parseInt(str.substring(2,str.length()))-1] = "";
						break;
					}
				}
			}

			// ?????£?????????????????????????????\
			StringBuilder sb = new StringBuilder();
			for(int i=0;i<mark.length;i++){
				for(int j=0;j<cards[i].length;j++){
					if(cards[i][j] == null)
						sb.append(mark[i]).append(" ").append((j+1)).append("\n");
				}
			}

			// ??????
			System.out.print(sb.toString());

		} catch (IOException e) {
			e.printStackTrace();
		}finally{
			try{
				if(br != null){
					br.close();
				}
			}catch(IOException ioe){
			}

		}
	}
}