#include <bits/stdc++.h>
using namespace std;
int main() {
  long long t = 1;
  while (t--) {
    long long n;
    cin >> n;
    string str;
    cin >> str;
    long long ans = 0;
    map<char, long long> mp;
    mp['R'] = 0;
    mp['G'] = 1;
    mp['B'] = 2;
    for (long long i = 1; i < n; i++) {
      if (str[i] == str[i - 1]) {
        ans++;
        int arr[3] = {0};
        arr[mp[str[i - 1]]] = 1;
        if (i != n - 1) {
          arr[mp[str[i + 1]]] = 1;
        }
        for (int z = 0; z < 3; z++)
          if (arr[z] == 0) {
            if (z == 0)
              str[i] = 'R';
            else if (z == 1)
              str[i] = 'G';
            else
              str[i] = 'B';
          }
      }
    }
    cout << ans << endl << str << endl;
  }
}
