#include <bits/stdc++.h>
using namespace std;
const long long mod = 1e9 + 9;
long long n, a, b, k, kk, ukk, uk;
string s, ss;
long long bigmod(long long b, long long p) {
  if (b == 0LL) return 0LL;
  long long ret = 1;
  while (p) {
    if (p & 1) ret = (ret * b) % mod;
    b = (b * b) % mod;
    p /= 2;
  }
  return ret % mod;
}
long long unit(long long kk) {
  long long ret = 0, x;
  for (int i = 0; i < kk; i++) {
    x = (bigmod(a, kk - i - 1LL) * bigmod(b, i * 1LL)) % mod;
    if (ss[i] == '-') x *= -1;
    x = (x + mod) % mod;
    ret = (ret + x) % mod;
  }
  return ret;
}
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cin >> n >> a >> b >> k >> s;
  kk = k;
  ss = s;
  ++n;
  while (kk < n && kk < 100000LL) ss += s, kk += k;
  ukk = unit(kk);
  uk = unit(k);
  long long print = 0LL, now = 0LL, nn = n, x;
  while (true) {
    if (now + kk <= n) {
      x = (bigmod(a, nn - kk) * bigmod(b, now)) % mod;
      x = (x * ukk) % mod;
      print = (print + x) % mod;
      nn -= kk;
      now += kk;
      if (now == n) break;
    } else {
      x = (bigmod(a, nn - k) * bigmod(b, now)) % mod;
      x = (x * uk) % mod;
      print = (print + x) % mod;
      nn -= k;
      now += k;
      if (now == n) break;
    }
  }
  cout << print << endl;
  return 0;
}
