gets;
cards = Array.new;
while s = gets do
  a = s.split(" ");
  i = a[1].to_i - 1;
  if s[0] == "S" then
    cards << i;
  elsif s[0] == "H" then
    cards << 13 + i;
  elsif s[0] == "C" then
    cards << 26 + i;
  elsif s[0] == "D" then
    cards << 39 + i;
  end
end

cards.sort!;

52.times{|i|
  unless cards.include?(i) then
    if i >= 39 then
      puts "D " + (i % 13 + 1).to_s;
    elsif i >= 13 * 2 then
      puts "C " + (i % 13 + 1).to_s;
    elsif i >= 13 then
      puts "H " + (i % 13 + 1).to_s;
    else
      puts "S " + (i + 1).to_s;
    end
  end
}