#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  int n;
  cin >> n;
  map<string, int> mp1;
  map<string, string> mp2;
  mp2["purple"] = "Power";
  mp2["green"] = "Time";
  mp2["blue"] = "Space";
  mp2["orange"] = "Soul";
  mp2["red"] = "Reality";
  mp2["yellow"] = "Mind";
  for (int i = 1; i <= n; i++) {
    string s;
    cin >> s;
    mp1[s] = 1;
  }
  int cnt = 0;
  for (auto it = mp2.begin(); it != mp2.end(); it++) {
    if (mp1[it->first] == 0) ++cnt;
  }
  cout << cnt << "\n";
  for (auto it = mp2.begin(); it != mp2.end(); it++) {
    if (mp1[it->first] == 0) cout << it->second << "\n";
  }
}
