#include <bits/stdc++.h>
using namespace std;
string st[6] = {"purple", "green", "blue", "orange", "red", "yellow"};
string name[6] = {"Power", "Time", "Space", "Soul", "Reality", "Mind"};
map<string, int> mp;
int main() {
  int n, m, i, j, k;
  string x, y;
  cin >> n;
  m = 6 - n;
  while (n--) {
    cin >> x;
    mp[x]++;
  }
  cout << m << endl;
  for (i = 0; i < 6; i++) {
    if (mp[st[i]] == 0) {
      cout << name[i] << endl;
    }
  }
  return 0;
}
