#include <iostream> #include <vector> #include <map> #include<string> #include<queue> #include<math.h> #define pb push_back #define all(x) begin(x),end(x) #define ll long long #define P pair<int,int> #define lP pait<ll,ll> using namespace std; int main() { char a,b,c,d; cin>>a>>b; c='F';d='F'; if(a=='T') d='T'; else if(b=='T') c='T'; cout<<c<<' '<<d<<endl; return 0; }