#include <bits/stdc++.h>
using namespace std;
int main() {
  string gems[][2] = {
      {"purple", "Power"}, {"green", "Time"},  {"blue", "Space"},
      {"orange", "Soul"},  {"red", "Reality"}, {"yellow", "Mind"},
  };
  int n;
  cin >> n;
  for (int i = 0; i < n; ++i) {
    string input;
    cin >> input;
    for (int j = 0; j < 6; ++j) {
      if (gems[j][0] == input) {
        gems[j][1] = "";
        break;
      }
    }
  }
  cout << 6 - n << endl;
  for (int i = 0; i < 6; ++i) {
    if (gems[i][1] != "") {
      cout << gems[i][1] << endl;
    }
  }
  return 0;
}
