#include <bits/stdc++.h>
using namespace std;
map<string, int> mp1;
map<string, string> mp2;
int cnt;
string s[6] = {"purple", "green", "blue", "orange", "red", "yellow"};
int main() {
  mp2[s[0]] = "Power";
  mp2[s[1]] = "Time";
  mp2[s[2]] = "Space";
  mp2[s[3]] = "Soul";
  mp2[s[4]] = "Reality";
  mp2[s[5]] = "Mind";
  int n;
  cin >> n;
  string str;
  while (n--) {
    cin >> str;
    mp1[str] = 1;
    cnt++;
  }
  if (6 - n) {
    cout << 6 - cnt << endl;
    for (int i = 0; i < 6; i++) {
      if (!mp1[s[i]]) cout << mp2[s[i]] << endl;
    }
  } else
    cout << "0" << endl;
  return 0;
}
