#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  int a[n], m = 0;
  for (int i = 0; i < n; i++) {
    char dl;
    cin >> dl;
    if (dl == 'R') a[i] = 0;
    if (dl == 'G') a[i] = 1;
    if (dl == 'B') a[i] = 2;
  }
  for (int i = 1; i < n - 1; i++) {
    if (a[i] == a[i - 1]) {
      a[i] = (a[i] + 1) % 3;
      if (a[i] == a[i + 1]) {
        a[i] = (a[i] + 1) % 3;
      }
      m++;
    }
  }
  if (a[n - 2] == a[n - 1]) {
    a[n - 1] = (a[n - 1] + 1) % 3;
    m++;
  }
  cout << m << endl;
  for (int i = 0; i < n; i++) {
    if (a[i] == 0) cout << "R";
    if (a[i] == 1) cout << "G";
    if (a[i] == 2) cout << "B";
  }
}
