function main(input){
  const args = input.split(" ");
  const a = args[0],
        b = args[1];
  
  if (a == "H")
    console.log(b);
  else
    if (b == "H")
      console.log("D");
    else
      console.log("H");
}

main(require('fs').readFileSync('/dev/stdin', 'utf8'));

