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