#include <bits/stdc++.h>
using namespace std;
void solve() {
  int n;
  cin >> n;
  string s;
  cin >> s;
  int ans = 0;
  if (n == 1) {
    cout << 0 << "\n";
    cout << s << "\n";
    return;
  }
  for (int i = 1; i < n - 1; i++) {
    if (s[i] == s[i - 1]) {
      ans++;
      if (s[i] != 'G' && s[i + 1] != 'G') {
        s[i] = 'G';
      } else if (s[i] != 'R' && s[i + 1] != 'R') {
        s[i] = 'R';
      } else if (s[i] != 'B' && s[i + 1] != 'B') {
        s[i] = 'B';
      }
    }
  }
  if (s[n - 1] == s[n - 2]) {
    ans++;
    if (s[n - 2] != 'G') {
      s[n - 1] = 'G';
    } else if (s[n - 2] != 'R') {
      s[n - 1] = 'R';
    } else if (s[n - 2] != 'B') {
      s[n - 1] = 'G';
    }
  }
  cout << ans << "\n";
  cout << s << "\n";
}
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  int t = 1;
  while (t--) solve();
}
