#include <bits/stdc++.h>
using namespace std;
long long mod = 1e9 + 9;
long long qm(long long a, long long b) {
  long long ans = 1;
  while (b > 0) {
    if (b & 1) ans = ans * a % mod;
    b >>= 1;
    a = a * a % mod;
  }
  return (ans % mod + mod) % mod;
}
char c[1000005];
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  long long n, a, b, k;
  cin >> n >> a >> b >> k;
  cin >> c;
  long long ans = 0;
  if (n + 1 <= k) {
    for (long long i = 0; i <= n; i++) {
      if (c[i] == '-') {
        ans = ans - qm(a, n - i) * qm(b, i);
        ans = (ans % mod + mod) % mod;
      } else {
        ans = ans + qm(a, n - i) * qm(b, i);
        ans = (ans % mod + mod) % mod;
      }
    }
    ans = (ans % mod + mod) % mod;
    cout << ans << endl;
  } else {
    long long t = (n + 1) / k;
    long long g = (n + 1) % k;
    long long x = 0;
    if (g == 0) {
      for (long long i = 0; i < k; i++) {
        if (c[i] == '-') {
          x = x - qm(a, n - i) * qm(b, i);
          x = (x % mod + mod) % mod;
        } else {
          x = x + qm(a, n - i) * qm(b, i);
          x = (x % mod + mod) % mod;
        }
      }
      if (qm(a, k) == qm(b, k)) {
        ans = t * x;
        ans = (ans % mod + mod) % mod;
        cout << ans << endl;
        return 0;
      }
      long long jj = qm(a, t * k) - qm(b, t * k);
      jj = x * jj % mod;
      jj = jj * qm(a, k) % mod;
      ;
      jj = jj % mod;
      long long nn = (qm(a, k) - qm(b, k));
      nn = nn % mod;
      nn = nn * qm(a, t * k);
      nn = nn % mod;
      nn = qm(nn, mod - 2);
      ans = jj * nn;
      ans = (ans % mod + mod) % mod;
      cout << ans << endl;
    } else {
      for (long long i = 0; i < k; i++) {
        if (c[i] == '-') {
          x = x - qm(a, n - i) * qm(b, i);
          x = (x % mod + mod) % mod;
        } else {
          x = x + qm(a, n - i) * qm(b, i);
          x = (x % mod + mod) % mod;
        }
      }
      if (qm(a, k) == qm(b, k)) {
        ans = t * x;
        ans = (ans % mod + mod) % mod;
        for (long long hh = 0; hh < g; hh++) {
          if (c[hh] == '-') {
            ans = ans - qm(a, n - (t * k + hh)) * qm(b, (t * k + hh));
            ans = (ans % mod + mod) % mod;
          } else {
            ans = ans + qm(a, n - (t * k + hh)) * qm(b, (t * k + hh));
            ans = (ans % mod + mod) % mod;
          }
        }
        ans = (ans % mod + mod) % mod;
        cout << ans << endl;
        return 0;
      }
      long long jj = qm(a, t * k) - qm(b, t * k);
      jj = x * jj % mod;
      jj = jj * qm(a, k) % mod;
      ;
      jj = jj % mod;
      long long nn = (qm(a, k) - qm(b, k));
      nn = nn % mod;
      nn = nn * qm(a, t * k);
      nn = nn % mod;
      nn = qm(nn, mod - 2);
      ans = jj * nn;
      ans = (ans % mod + mod) % mod;
      for (long long hh = 0; hh < g; hh++) {
        if (c[hh] == '-') {
          ans = ans - qm(a, n - (t * k + hh)) * qm(b, (t * k + hh));
          ans = (ans % mod + mod) % mod;
        } else {
          ans = ans + qm(a, n - (t * k + hh)) * qm(b, (t * k + hh));
          ans = (ans % mod + mod) % mod;
        }
      }
      ans = (ans % mod + mod) % mod;
      cout << ans << endl;
    }
  }
}
