#include <bits/stdc++.h>
using namespace std;
bool isPowerOfTwo(long long int x) { return x && (!(x & (x - 1))); }
void solve() {
  long long int n;
  cin >> n;
  map<string, string> hash;
  hash["purple"] = "Power";
  hash["green"] = "Time";
  hash["blue"] = "Space";
  hash["orange"] = "Soul";
  hash["red"] = "Reality";
  hash["yellow"] = "Mind";
  for (long long int i = 0; i < n; ++i) {
    string str;
    cin >> str;
    hash.erase(str);
  }
  cout << hash.size() << "\n";
  for (auto it : hash) cout << it.second << "\n";
}
int32_t main() {
  std::ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  int T = 1;
  while (T--) solve();
  return 0;
}
