#include <bits/stdc++.h>
#include <stdio.h>
using namespace std;
int main(){
char a,b;
cin >>a>>b;
if (a=='H'){
    if (b=='H')
        cout<<"H"<<endl;
    else if(b=='D')
        cout<<"D"<<endl;
      
}else if (a=='D'){
    if (b=='D')
        cout<<"H"<<endl;
    else if(b=='H')
        cout<<"D"<<endl;
}

return 0;
}