#include <bits/stdc++.h>
using namespace std;
long long n, a, b;
long long h[20];
long long dp[20][20][20];
long long num[20][20][20];
long long hl[20][20][20];
vector<long long> v;
long long rec(long long i, long long j, long long k) {
  if (i == n - 1) {
    if (j > 0)
      return 2000000000000000005;
    else
      return 0;
  }
  if (dp[i][j][k] < 5000) {
    return dp[i][j][k];
  }
  long long newh = h[i] - k * b;
  for (long long first = 0; first < 16; first++) {
    if (first * b < j) continue;
    long long second = first + rec(i + 1, max(0LL, newh - first * a), first);
    if (second < dp[i][j][k]) {
      dp[i][j][k] = second;
      num[i][j][k] = first;
      hl[i][j][k] = max(0LL, newh - first * a);
    }
  }
  return dp[i][j][k];
}
void finalize(long long i, long long j, long long k) {
  if (i == n - 1) {
    return;
  }
  long long first = num[i][j][k];
  while (first--) v.push_back(i);
  finalize(i + 1, hl[i][j][k], num[i][j][k]);
}
void solve() {
  cin >> n >> a >> b;
  for (long long i = 0; i < n; i++) {
    cin >> h[i];
    h[i]++;
  }
  memset(dp, 2000000000000000005, sizeof dp);
  while (h[0] > 0) {
    h[1] -= a;
    h[0] -= b;
    h[2] -= b;
    h[1] = max(h[1], 0LL);
    h[2] = max(h[2], 0LL);
    h[0] = max(h[0], 0LL);
    v.push_back(1);
  }
  while (h[n - 1] > 0) {
    h[n - 1] -= b;
    h[n - 2] -= a;
    h[n - 3] -= b;
    h[n - 1] = max(h[n - 1], 0LL);
    h[n - 2] = max(h[n - 2], 0LL);
    h[n - 3] = max(h[n - 3], 0LL);
    v.push_back(n - 2);
  }
  rec(1, 0, 0);
  finalize(1, 0, 0);
  cout << v.size() << "\n";
  for (auto it : v) {
    cout << it + 1 << " ";
  }
  cout << "\n";
}
signed main() {
  ios_base ::sync_with_stdio(0);
  cin.tie(NULL);
  cout.tie(NULL);
  solve();
  return 0;
}
