public class Main{
  public void run(java.io.InputStream in, java.io.PrintStream out){
    java.util.Scanner sc = new java.util.Scanner(in);
/*answer*/
    int n;
    int[] s, h, c, d;
    int i, a;
    String str;

    n = sc.nextInt();
    s = new int[13];
    h = new int[13];
    c = new int[13];
    d = new int[13];

    for(i = 0;i < n;i++){
      str = sc.next();
      a = sc.nextInt();
      if("S".equals(str)){
        s[a - 1] = 1;
      }else if("H".equals(str)){
        h[a - 1] = 1;
      }else if("C".equals(str)){
        c[a - 1] = 1;
      }else{
        d[a - 1] = 1;
      }
    }

    for(i = 0;i < 13;i++){
      if(s[i] != 1){
        System.out.println("S " + (i + 1));
      }
    }
    for(i = 0;i < 13;i++){
      if(h[i] != 1){
        System.out.println("H " + (i + 1));
      }
    }
    for(i = 0;i < 13;i++){
      if(c[i] != 1){
        System.out.println("C " + (i + 1));
      }
    }
    for(i = 0;i < 13;i++){
      if(d[i] != 1){
        System.out.println("D " + (i + 1));
      }
    }

    sc.close();
  }
  public static void main(String[] args){
    (new Main()).run(System.in, System.out);
  }

} public class Main{
  public void run(java.io.InputStream in, java.io.PrintStream out){
    java.util.Scanner sc = new java.util.Scanner(in);
/*answer*/
    int n;
    int[] s, h, c, d;
    int i, a;
    String str;

    n = sc.nextInt();
    s = new int[13];
    h = new int[13];
    c = new int[13];
    d = new int[13];

    for(i = 0;i < n;i++){
      str = sc.next();
      a = sc.nextInt();
      if("S".equals(str)){
        s[a - 1] = 1;
      }else if("H".equals(str)){
        h[a - 1] = 1;
      }else if("C".equals(str)){
        c[a - 1] = 1;
      }else{
        d[a - 1] = 1;
      }
    }

    for(i = 0;i < 13;i++){
      if(s[i] != 1){
        System.out.println("S " + (i + 1));
      }
    }
    for(i = 0;i < 13;i++){
      if(h[i] != 1){
        System.out.println("H " + (i + 1));
      }
    }
    for(i = 0;i < 13;i++){
      if(c[i] != 1){
        System.out.println("C " + (i + 1));
      }
    }
    for(i = 0;i < 13;i++){
      if(d[i] != 1){
        System.out.println("D " + (i + 1));
      }
    }

    sc.close();
  }
  public static void main(String[] args){
    (new Main()).run(System.in, System.out);
  }

} Main public void run(java.io.InputStream in, java.io.PrintStream out){
    java.util.Scanner sc = new java.util.Scanner(in);
/*answer*/
    int n;
    int[] s, h, c, d;
    int i, a;
    String str;

    n = sc.nextInt();
    s = new int[13];
    h = new int[13];
    c = new int[13];
    d = new int[13];

    for(i = 0;i < n;i++){
      str = sc.next();
      a = sc.nextInt();
      if("S".equals(str)){
        s[a - 1] = 1;
      }else if("H".equals(str)){
        h[a - 1] = 1;
      }else if("C".equals(str)){
        c[a - 1] = 1;
      }else{
        d[a - 1] = 1;
      }
    }

    for(i = 0;i < 13;i++){
      if(s[i] != 1){
        System.out.println("S " + (i + 1));
      }
    }
    for(i = 0;i < 13;i++){
      if(h[i] != 1){
        System.out.println("H " + (i + 1));
      }
    }
    for(i = 0;i < 13;i++){
      if(c[i] != 1){
        System.out.println("C " + (i + 1));
      }
    }
    for(i = 0;i < 13;i++){
      if(d[i] != 1){
        System.out.println("D " + (i + 1));
      }
    }

    sc.close();
  } run {
    java.util.Scanner sc = new java.util.Scanner(in);
/*answer*/
    int n;
    int[] s, h, c, d;
    int i, a;
    String str;

    n = sc.nextInt();
    s = new int[13];
    h = new int[13];
    c = new int[13];
    d = new int[13];

    for(i = 0;i < n;i++){
      str = sc.next();
      a = sc.nextInt();
      if("S".equals(str)){
        s[a - 1] = 1;
      }else if("H".equals(str)){
        h[a - 1] = 1;
      }else if("C".equals(str)){
        c[a - 1] = 1;
      }else{
        d[a - 1] = 1;
      }
    }

    for(i = 0;i < 13;i++){
      if(s[i] != 1){
        System.out.println("S " + (i + 1));
      }
    }
    for(i = 0;i < 13;i++){
      if(h[i] != 1){
        System.out.println("H " + (i + 1));
      }
    }
    for(i = 0;i < 13;i++){
      if(c[i] != 1){
        System.out.println("C " + (i + 1));
      }
    }
    for(i = 0;i < 13;i++){
      if(d[i] != 1){
        System.out.println("D " + (i + 1));
      }
    }

    sc.close();
  } java.util.Scanner sc = new java.util.Scanner(in); sc new java.util.Scanner(in) int n; n int[] s s h h c c d; d int i i a; a String str; str n = sc.nextInt() n sc.nextInt() sc.nextInt sc s = new int[13] s new int[13] 13 h = new int[13] h new int[13] 13 c = new int[13] c new int[13] 13 d = new int[13] d new int[13] 13 for(i = 0;i < n;i++){
      str = sc.next();
      a = sc.nextInt();
      if("S".equals(str)){
        s[a - 1] = 1;
      }else if("H".equals(str)){
        h[a - 1] = 1;
      }else if("C".equals(str)){
        c[a - 1] = 1;
      }else{
        d[a - 1] = 1;
      }
    } i = 0; i = 0 i 0 i < n i n i++ i++ i {
      str = sc.next();
      a = sc.nextInt();
      if("S".equals(str)){
        s[a - 1] = 1;
      }else if("H".equals(str)){
        h[a - 1] = 1;
      }else if("C".equals(str)){
        c[a - 1] = 1;
      }else{
        d[a - 1] = 1;
      }
    } {
      str = sc.next();
      a = sc.nextInt();
      if("S".equals(str)){
        s[a - 1] = 1;
      }else if("H".equals(str)){
        h[a - 1] = 1;
      }else if("C".equals(str)){
        c[a - 1] = 1;
      }else{
        d[a - 1] = 1;
      }
    } str = sc.next() str sc.next() sc.next sc a = sc.nextInt() a sc.nextInt() sc.nextInt sc if("S".equals(str)){
        s[a - 1] = 1;
      }else if("H".equals(str)){
        h[a - 1] = 1;
      }else if("C".equals(str)){
        c[a - 1] = 1;
      }else{
        d[a - 1] = 1;
      } "S".equals(str) "S".equals "S" str {
        s[a - 1] = 1;
      } s[a - 1] = 1 s[a - 1] s a - 1 a 1 1 if("H".equals(str)){
        h[a - 1] = 1;
      }else if("C".equals(str)){
        c[a - 1] = 1;
      }else{
        d[a - 1] = 1;
      } "H".equals(str) "H".equals "H" str {
        h[a - 1] = 1;
      } h[a - 1] = 1 h[a - 1] h a - 1 a 1 1 if("C".equals(str)){
        c[a - 1] = 1;
      }else{
        d[a - 1] = 1;
      } "C".equals(str) "C".equals "C" str {
        c[a - 1] = 1;
      } c[a - 1] = 1 c[a - 1] c a - 1 a 1 1 {
        d[a - 1] = 1;
      } d[a - 1] = 1 d[a - 1] d a - 1 a 1 1 for(i = 0;i < 13;i++){
      if(s[i] != 1){
        System.out.println("S " + (i + 1));
      }
    } i = 0; i = 0 i 0 i < 13 i 13 i++ i++ i {
      if(s[i] != 1){
        System.out.println("S " + (i + 1));
      }
    } {
      if(s[i] != 1){
        System.out.println("S " + (i + 1));
      }
    } if(s[i] != 1){
        System.out.println("S " + (i + 1));
      } s[i] != 1 s[i] s i 1 {
        System.out.println("S " + (i + 1));
      } System.out.println("S " + (i + 1)) System.out.println System.out System System.out "S " + (i + 1) "S " (i + 1) i 1 for(i = 0;i < 13;i++){
      if(h[i] != 1){
        System.out.println("H " + (i + 1));
      }
    } i = 0; i = 0 i 0 i < 13 i 13 i++ i++ i {
      if(h[i] != 1){
        System.out.println("H " + (i + 1));
      }
    } {
      if(h[i] != 1){
        System.out.println("H " + (i + 1));
      }
    } if(h[i] != 1){
        System.out.println("H " + (i + 1));
      } h[i] != 1 h[i] h i 1 {
        System.out.println("H " + (i + 1));
      } System.out.println("H " + (i + 1)) System.out.println System.out System System.out "H " + (i + 1) "H " (i + 1) i 1 for(i = 0;i < 13;i++){
      if(c[i] != 1){
        System.out.println("C " + (i + 1));
      }
    } i = 0; i = 0 i 0 i < 13 i 13 i++ i++ i {
      if(c[i] != 1){
        System.out.println("C " + (i + 1));
      }
    } {
      if(c[i] != 1){
        System.out.println("C " + (i + 1));
      }
    } if(c[i] != 1){
        System.out.println("C " + (i + 1));
      } c[i] != 1 c[i] c i 1 {
        System.out.println("C " + (i + 1));
      } System.out.println("C " + (i + 1)) System.out.println System.out System System.out "C " + (i + 1) "C " (i + 1) i 1 for(i = 0;i < 13;i++){
      if(d[i] != 1){
        System.out.println("D " + (i + 1));
      }
    } i = 0; i = 0 i 0 i < 13 i 13 i++ i++ i {
      if(d[i] != 1){
        System.out.println("D " + (i + 1));
      }
    } {
      if(d[i] != 1){
        System.out.println("D " + (i + 1));
      }
    } if(d[i] != 1){
        System.out.println("D " + (i + 1));
      } d[i] != 1 d[i] d i 1 {
        System.out.println("D " + (i + 1));
      } System.out.println("D " + (i + 1)) System.out.println System.out System System.out "D " + (i + 1) "D " (i + 1) i 1 sc.close() sc.close sc java.io.InputStream in in java.io.PrintStream out out public static void main(String[] args){
    (new Main()).run(System.in, System.out);
  } main {
    (new Main()).run(System.in, System.out);
  } (new Main()).run(System.in, System.out) (new Main()).run (new Main()) System.in System System.in System.out System System.out String[] args args public class Main{
  public void run(java.io.InputStream in, java.io.PrintStream out){
    java.util.Scanner sc = new java.util.Scanner(in);
/*answer*/
    int n;
    int[] s, h, c, d;
    int i, a;
    String str;

    n = sc.nextInt();
    s = new int[13];
    h = new int[13];
    c = new int[13];
    d = new int[13];

    for(i = 0;i < n;i++){
      str = sc.next();
      a = sc.nextInt();
      if("S".equals(str)){
        s[a - 1] = 1;
      }else if("H".equals(str)){
        h[a - 1] = 1;
      }else if("C".equals(str)){
        c[a - 1] = 1;
      }else{
        d[a - 1] = 1;
      }
    }

    for(i = 0;i < 13;i++){
      if(s[i] != 1){
        System.out.println("S " + (i + 1));
      }
    }
    for(i = 0;i < 13;i++){
      if(h[i] != 1){
        System.out.println("H " + (i + 1));
      }
    }
    for(i = 0;i < 13;i++){
      if(c[i] != 1){
        System.out.println("C " + (i + 1));
      }
    }
    for(i = 0;i < 13;i++){
      if(d[i] != 1){
        System.out.println("D " + (i + 1));
      }
    }

    sc.close();
  }
  public static void main(String[] args){
    (new Main()).run(System.in, System.out);
  }

} public class Main{
  public void run(java.io.InputStream in, java.io.PrintStream out){
    java.util.Scanner sc = new java.util.Scanner(in);
/*answer*/
    int n;
    int[] s, h, c, d;
    int i, a;
    String str;

    n = sc.nextInt();
    s = new int[13];
    h = new int[13];
    c = new int[13];
    d = new int[13];

    for(i = 0;i < n;i++){
      str = sc.next();
      a = sc.nextInt();
      if("S".equals(str)){
        s[a - 1] = 1;
      }else if("H".equals(str)){
        h[a - 1] = 1;
      }else if("C".equals(str)){
        c[a - 1] = 1;
      }else{
        d[a - 1] = 1;
      }
    }

    for(i = 0;i < 13;i++){
      if(s[i] != 1){
        System.out.println("S " + (i + 1));
      }
    }
    for(i = 0;i < 13;i++){
      if(h[i] != 1){
        System.out.println("H " + (i + 1));
      }
    }
    for(i = 0;i < 13;i++){
      if(c[i] != 1){
        System.out.println("C " + (i + 1));
      }
    }
    for(i = 0;i < 13;i++){
      if(d[i] != 1){
        System.out.println("D " + (i + 1));
      }
    }

    sc.close();
  }
  public static void main(String[] args){
    (new Main()).run(System.in, System.out);
  }

} Main
public class Main{
  public void run(java.io.InputStream in, java.io.PrintStream out){
    java.util.Scanner sc = new java.util.Scanner(in);
/*answer*/
    int n;
    int[] s, h, c, d;
    int i, a;
    String str;

    n = sc.nextInt();
    s = new int[13];
    h = new int[13];
    c = new int[13];
    d = new int[13];

    for(i = 0;i < n;i++){
      str = sc.next();
      a = sc.nextInt();
      if("S".equals(str)){
        s[a - 1] = 1;
      }else if("H".equals(str)){
        h[a - 1] = 1;
      }else if("C".equals(str)){
        c[a - 1] = 1;
      }else{
        d[a - 1] = 1;
      }
    }

    for(i = 0;i < 13;i++){
      if(s[i] != 1){
        System.out.println("S " + (i + 1));
      }
    }
    for(i = 0;i < 13;i++){
      if(h[i] != 1){
        System.out.println("H " + (i + 1));
      }
    }
    for(i = 0;i < 13;i++){
      if(c[i] != 1){
        System.out.println("C " + (i + 1));
      }
    }
    for(i = 0;i < 13;i++){
      if(d[i] != 1){
        System.out.println("D " + (i + 1));
      }
    }

    sc.close();
  }
  public static void main(String[] args){
    (new Main()).run(System.in, System.out);
  }

}