#include <bits/stdc++.h>
using namespace std;
const int mod = 1e9 + 7;
const int N = 1e5 + 123;
const int inf = 1e9 + 123;
const long long INF = 1e18;
const double eps = 1e-5;
int n;
string s;
int main() {
  ios_base::sync_with_stdio(0), cin.tie(0), cout.tie(0);
  cin >> n;
  cin >> s;
  vector<int> v;
  v.push_back(1);
  v.push_back(2);
  v.push_back(3);
  int ans = n;
  vector<int> a1;
  do {
    int col = 0;
    for (int i = 0; i < n; i++) {
      if (s[i] == 'R') {
        if (1 != v[i % 3]) {
          col++;
        }
      }
      if (s[i] == 'G') {
        if (2 != v[i % 3]) {
          col++;
        }
      }
      if (s[i] == 'B') {
        if (3 != v[i % 3]) {
          col++;
        }
      }
    }
    if (ans > col) {
      ans = col;
      a1.clear();
      a1.push_back(v[0]);
      a1.push_back(v[1]);
      a1.push_back(v[2]);
    }
  } while (next_permutation(v.begin(), v.end()));
  cout << ans << endl;
  for (int i = 0; i < n; i++) {
    if (a1[i % 3] == 1) {
      cout << 'R';
    }
    if (a1[i % 3] == 2) {
      cout << 'G';
    }
    if (a1[i % 3] == 3) {
      cout << 'B';
    }
  }
  return 0;
}
