#include <bits/stdc++.h>
using namespace std;
int main() {
  int per[6][3] = {0, 1, 2, 0, 2, 1, 1, 0, 2, 1, 2, 0, 2, 0, 1, 2, 1, 0};
  char col[3] = {'R', 'G', 'B'};
  int n;
  cin >> n;
  cin.ignore(numeric_limits<streamsize>::max(), '\n');
  string s;
  getline(cin, s);
  int c;
  int i;
  int cl = INT_MAX;
  int jl = 6;
  for (int j = 0; j < 6; j++) {
    i = 0;
    c = 0;
    while (i != n) {
      if (s[i] != col[per[j][i % 3]]) {
        c++;
      }
      i++;
    }
    if (c < cl) {
      cl = c;
      jl = j;
    }
  }
  cout << cl << endl;
  for (int i = 0; i < n; i++) {
    cout << col[per[jl][i % 3]];
  }
  return 0;
}
