#include <bits/stdc++.h>
using namespace std;
int main() {
  string s1 = "ROYGBIV", ans = "";
  int n;
  scanf("%d", &n);
  int n1, n2;
  n1 = n / 7;
  n2 = n % 7;
  for (int i = 0; i < n1; ++i) {
    ans = ans + s1;
  }
  if (n2 != 0) {
    if (n2 < 4) {
      s1 = s1.substr(3, n2);
      ans = ans + s1;
    } else {
      s1 = s1.substr(0, n2);
      ans = ans + s1;
    }
  }
  cout << ans << endl;
  return 0;
}
