#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  vector<string> colors;
  colors.push_back("purple");
  colors.push_back("green");
  colors.push_back("blue");
  colors.push_back("orange");
  colors.push_back("red");
  colors.push_back("yellow");
  map<string, string> c;
  c["purple"] = "Power";
  c["green"] = "Time";
  c["blue"] = "Space";
  c["orange"] = "Soul";
  c["red"] = "Reality";
  c["yellow"] = "Mind";
  for (int i = 0; i < n; i++) {
    string s;
    cin >> s;
    colors.erase(find(colors.begin(), colors.end(), s));
  }
  cout << colors.size() << endl;
  for (string x : colors) {
    cout << c[x] << endl;
  }
}
