#include <bits/stdc++.h>
using namespace std;
string s[6] = {"purple", "green", "blue", "orange", "red", "yellow"};
string ans[6] = {"Power", "Time", "Space", "Soul", "Reality", "Mind"};
bool have[6];
int main() {
  cin.tie();
  ios_base::sync_with_stdio(0);
  int n;
  cin >> n;
  int m = 6 - n;
  string t;
  for (int i = 0; i < n; ++i) {
    cin >> t;
    for (int j = 0; j < 6; ++j) {
      if (t == s[j]) {
        have[j] = true;
        break;
      }
    }
  }
  cout << m << "\n";
  for (int i = 0; i < 6; ++i) {
    if (!have[i]) {
      cout << ans[i] << "\n";
    }
  }
  return 0;
}
