#include <bits/stdc++.h>
using namespace std;
char str[100005];
int main() {
  ios::sync_with_stdio(0);
  long long n, k, a, b;
  cin >> n >> k >> a >> b;
  bool fail = false;
  if (a == b) {
    for (int i = 0; i < n; i++) {
      str[i++] = 'G';
      str[i] = 'B';
    }
  } else if (a > b) {
    for (int i = 0; i < n; i++) {
      if (a > (k * (b + 1ll)))
        fail = true;
      else {
        long long index = 0ll;
        long long nk = k;
        while (a > 0 || b > 0) {
          if (a <= k && b <= k) {
            for (long long i = 0ll; i < a; i++) str[index++] = 'G';
            for (long long i = 0ll; i < b; i++) str[index++] = 'B';
            break;
          }
          long long na = a - k;
          long long nb = b - nk;
          if (na > k * (nb + 1ll))
            nk--;
          else {
            for (long long i = 0ll; i < k; i++) str[index++] = 'G';
            for (long long i = 0ll; i < nk; i++) str[index++] = 'B';
            a -= k;
            b -= nk;
          }
        }
      }
    }
  } else {
    for (int i = 0; i < n; i++) {
      if (b > (k * (a + 1ll)))
        fail = true;
      else {
        long long index = 0ll;
        long long nk = k;
        while (a > 0 || b > 0) {
          if (a <= k && b <= k) {
            for (long long i = 0ll; i < b; i++) str[index++] = 'B';
            for (long long i = 0ll; i < a; i++) str[index++] = 'G';
            break;
          }
          long long na = a - nk;
          long long nb = b - k;
          if (nb > k * (na + 1ll))
            nk--;
          else {
            for (long long i = 0ll; i < k; i++) str[index++] = 'B';
            for (long long i = 0ll; i < nk; i++) str[index++] = 'G';
            a -= nk;
            b -= k;
          }
        }
      }
    }
  }
  if (fail)
    cout << "NO";
  else {
    str[n] = '\0';
    cout << str;
  }
  return 0;
}
