object Main extends App {
  val sc = new java.util.Scanner(System.in)
  val a, b = sc.next()
  a match {
    case "H" if b == "H" => "H"
    case "H" => "D"
    case "D" if b == "D" => "H"
    case _ => "D"
  }
}
