#include <bits/stdc++.h>
using namespace std;
const int MX = 112345;
const long long mod = 1e9 + 9;
long long n, a, b, k;
char sgn[MX];
long long bigMod(long long b, long long p) {
  long long x = 1LL;
  for (; p > 0; p /= 2) {
    if (p & 1) x = (x * b) % mod;
    b = (b * b) % mod;
  }
  return x % mod;
}
int main() {
  ios_base ::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  cin >> n >> a >> b >> k >> sgn;
  long long q, mlt, d, aibi, tmp, res = 0LL;
  d = (n + 1) / k;
  q = (bigMod(b, k) % mod * bigMod(bigMod(a, k), mod - 2) % mod) % mod;
  mlt = ((bigMod(q, d) - 1 + mod) % mod * bigMod(q - 1 + mod, mod - 2) % mod) %
        mod;
  aibi = bigMod(a, n) % mod;
  for (int i = 0; i < k; i++) {
    tmp = (aibi % mod * mlt % mod) % mod;
    if (q == 1) tmp = (aibi * d) % mod;
    if (sgn[i] == '-')
      res = (res - tmp + mod) % mod;
    else
      res = (res + tmp + mod) % mod;
    aibi = (aibi % mod * b % mod * bigMod(a, mod - 2) % mod) % mod;
  }
  cout << res << endl;
  return 0;
}
