#include <bits/stdc++.h>
using namespace std;
const int maxn = 10e5;
int main() {
  ios::sync_with_stdio(0), cin.tie(0), cout.tie(0);
  int n, ch = 0;
  string s, ans;
  cin >> n >> s;
  string chars = "RGB";
  ans = s;
  for (int i = 0; i < n - 2; i++) {
    if (ans[i + 1] == ans[i]) {
      for (int p = 0; p < 3; p++)
        if (ans[i] != chars[p] && ans[i + 2] != chars[p]) ans[i + 1] = chars[p];
      ch++;
    }
  }
  if (n > 1 && ans[n - 2] == ans[n - 1]) {
    for (int p = 0; p < 3; p++)
      if (s[n - 2] != chars[p]) ans[n - 1] = chars[p];
    ch++;
  }
  cout << ch << "\n" << ans;
  return 0;
}
