#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
const double eps = 1e-10;
const int MAXN = 1e7 + 6;
const int MOD = 1e9 + 7;
bool ODD(ll O) { return (O % 2 != 0); }
int gcd(ll a, ll b) {
  if (a == 0) return b;
  return gcd(b % a, a);
}
int dx[] = {1, 0, -1, 0, -1, 0};
int dy[] = {0, 1, 0, -1, -1, 0};
string s;
string ts = "";
vector<char> vc;
int main() {
  int n;
  cin >> n >> s;
  vc.push_back('R');
  vc.push_back('G');
  vc.push_back('B');
  sort(vc.begin(), vc.end());
  int ans = 1e9 + 2;
  string a;
  do {
    string org = "";
    for (int i = 0; i < int(3); i++) org += vc[i];
    ts = "";
    for (int i = 0; i < int(200005); i++) {
      ts += org[i % 3];
    }
    for (int i = 0; i < int(3); i++) {
      int cnt = 0;
      string sans = "";
      for (int j = i; j < n + i; j++) {
        if (ts[j] != s[j - i]) ++cnt;
        sans += ts[j];
      }
      if (cnt < ans) {
        ans = cnt;
        a = sans;
      }
    }
  } while (next_permutation(vc.begin(), vc.end()));
  cout << ans << "\n" << a;
  return 0;
}
