#include <bits/stdc++.h>
using namespace std;
const long long MOD = 1e9 + 7;
int main() {
  ios::sync_with_stdio(false);
  long long n;
  string s;
  cin >> n >> s;
  string s1 = "", s2 = "", s3 = "", s4 = "", s5 = "", s6 = "";
  for (int i = 0; i < n; i++) {
    if (i % 3 == 0) {
      s1 += "R";
      s2 += "R";
      s3 += "B";
      s4 += "G";
      s5 += "G";
      s6 += "B";
    } else if (i % 3 == 1) {
      s1 += "G";
      s2 += "B";
      s3 += "R";
      s4 += "R";
      s5 += "B";
      s6 += "G";
    } else {
      s1 += "B";
      s2 += "G";
      s3 += "G";
      s4 += "B";
      s5 += "R";
      s6 += "R";
    }
  }
  long long c1 = 0, c2 = 0, c3 = 0, c4 = 0, c5 = 0, c6 = 0;
  for (int i = 0; i < n; i++) {
    if (s[i] != s1[i]) c1++;
    if (s[i] != s2[i]) c2++;
    if (s[i] != s3[i]) c3++;
    if (s[i] != s4[i]) c4++;
    if (s[i] != s5[i]) c5++;
    if (s[i] != s6[i]) c6++;
  }
  set<pair<long long, string> > st;
  st.insert(make_pair(c1, s1));
  st.insert(make_pair(c2, s2));
  st.insert(make_pair(c3, s3));
  st.insert(make_pair(c4, s4));
  st.insert(make_pair(c5, s5));
  st.insert(make_pair(c6, s6));
  cout << (*st.begin()).first << "\n" << (*st.begin()).second << "\n";
}
