#include <bits/stdc++.h>
using namespace std;
const int maxn = 2e5 + 7;
const int mod = 1e9 + 7;
int n;
char s[maxn];
char ch[] = "RGB";
int main() {
  scanf("%d", &n);
  scanf("%s", s);
  int cost = 0;
  for (int i = 1; i < n; ++i) {
    if (s[i] == s[i - 1]) {
      ++cost;
      for (int j = 0; j < 3; ++j) {
        if (ch[j] != s[i - 1]) {
          if (i + 1 < n) {
            if (ch[j] != s[i + 1]) {
              s[i] = ch[j];
              break;
            } else {
              continue;
            }
          }
          s[i] = ch[j];
          break;
        }
      }
    }
  }
  printf("%d\n%s\n", cost, s);
  return 0;
}
