#include <iostream>
#include <cstdio>
#include <cmath>
#include <cstdio>
#include <cstring>
#include <string>
#include <vector>
#include <set>
#include <map>
#include <stack>
#include <queue>
#include <deque>
#include <algorithm>

#define CK(N,A,B) (A<=N&&N<B)
#define REP(i,a,b) for(int i=a;i<b;i++)
#define RREP(i,a,b) for(int i=(b-1);a<=i;i--)
#define F first
#define S second
#define ll long long

const int INF = 1e9;
const long long  LLINF = 1e15;

using namespace std;

string S;

int ind;
int state = 0;
bool parse(){
  if(ind == S.size()) return false;
  bool ret = true;
  if(S[ind] == 'm'){
    ind++;
    while(S[ind]!='w'){
      state = 1;
      bool tmp = parse();
      if(!tmp) return false;
    }
    ind++;
  }else if(state == 1 && S[ind] == 'e'){
    state = 2;
    ind++;
    ret = true;
  }else if(state == 2 && S[ind] == 'w'){
    state = 0;
    ind++;
    ret = true;
  }else{
    ret = false;
  }
  return ret;
}

int main(){
  cin>>S;
  ind = 0;
  if(parse() && ind == S.size()) cout<<"Cat"<<endl;
  else cout<<"Rabbit"<<endl;
  return 0;
}
### Prompt

Your challenge is to write a CPP solution to the following problem:

Example

Input

mmemewwemeww


Output

Cat

### Response

```cpp
#include <iostream>
#include <cstdio>
#include <cmath>
#include <cstdio>
#include <cstring>
#include <string>
#include <vector>
#include <set>
#include <map>
#include <stack>
#include <queue>
#include <deque>
#include <algorithm>

#define CK(N,A,B) (A<=N&&N<B)
#define REP(i,a,b) for(int i=a;i<b;i++)
#define RREP(i,a,b) for(int i=(b-1);a<=i;i--)
#define F first
#define S second
#define ll long long

const int INF = 1e9;
const long long  LLINF = 1e15;

using namespace std;

string S;

int ind;
int state = 0;
bool parse(){
  if(ind == S.size()) return false;
  bool ret = true;
  if(S[ind] == 'm'){
    ind++;
    while(S[ind]!='w'){
      state = 1;
      bool tmp = parse();
      if(!tmp) return false;
    }
    ind++;
  }else if(state == 1 && S[ind] == 'e'){
    state = 2;
    ind++;
    ret = true;
  }else if(state == 2 && S[ind] == 'w'){
    state = 0;
    ind++;
    ret = true;
  }else{
    ret = false;
  }
  return ret;
}

int main(){
  cin>>S;
  ind = 0;
  if(parse() && ind == S.size()) cout<<"Cat"<<endl;
  else cout<<"Rabbit"<<endl;
  return 0;
}
```