Problem: You've got a non-decreasing sequence x1, x2, ..., xn (1 ≤ x1 ≤ x2 ≤ ... ≤ xn ≤ q). You've also got two integers a and b (a ≤ b; a·(n - 1) < q).

Your task is to transform sequence x1, x2, ..., xn into some sequence y1, y2, ..., yn (1 ≤ yi ≤ q; a ≤ yi + 1 - yi ≤ b). The transformation price is the following sum: <image>. Your task is to choose such sequence y that minimizes the described transformation price.

Input

The first line contains four integers n, q, a, b (2 ≤ n ≤ 6000; 1 ≤ q, a, b ≤ 109; a·(n - 1) < q; a ≤ b).

The second line contains a non-decreasing integer sequence x1, x2, ..., xn (1 ≤ x1 ≤ x2 ≤ ... ≤ xn ≤ q).

Output

In the first line print n real numbers — the sought sequence y1, y2, ..., yn (1 ≤ yi ≤ q; a ≤ yi + 1 - yi ≤ b). In the second line print the minimum transformation price, that is, <image>.

If there are multiple optimal answers you can print any of them.

The answer will be considered correct if the absolute or relative error doesn't exceed 10 - 6.

Examples

Input

3 6 2 2
1 4 6


Output

1.666667 3.666667 5.666667 
0.666667


Input

10 100000 8714 9344
3378 14705 17588 22672 32405 34309 37446 51327 81228 94982


Output

1.000000 8715.000000 17429.000000 26143.000000 34857.000000 43571.000000 52285.000000 61629.000000 70973.000000 80317.000000 
797708674.000000

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
typedef struct node* ntp;
ntp st[110000], rt;
struct node {
  ntp c[2], f;
  double x, dx, y, k, b;
  inline int d(void) { return f->c[1] == this; }
  inline void sc(ntp x, int d) {
    if (this)
      if (c[d] = x) x->f = this;
  }
  inline void rot(void) {
    ntp p = f;
    int dd = d();
    if (!p->f)
      f = NULL, rt = this;
    else
      p->f->sc(this, p->d());
    p->sc(c[!dd], dd), sc(p, !dd);
  }
  inline void down(int x) {
    if (c[x]) c[x]->b += b - dx * c[x]->k, c[x]->dx += dx, c[x]->k += k;
  }
  inline void down(void) {
    if (!this) return;
    x += dx, y += k * x + b, down(0), down(1), k = b = dx = 0;
  }
  void push(void) {
    ntp t = this;
    int top = 0;
    while (t) st[++top] = t, t = t->f;
    while (top) st[top--]->down();
  }
  void splay(void) {
    push();
    while (f) {
      if (!f->f)
        rot();
      else
        (f->d() == d() ? f : this)->rot(), rot();
    }
  }
  ntp next(int x) {
    down();
    ntp t = c[x];
    while (t->c[!x]) (t = t->c[!x])->down();
    return t;
  }
  ntp get(void) {
    ntp t = this, s = NULL;
    down();
    while (true) {
      if (t->y > 0) s = t;
      if (fabs(t->y) <= 1E-12) return t;
      bool d = t->y < 0;
      if (!t->c[d]) return s;
      (t = t->c[d])->down();
    }
  }
  void print(void) {
    down();
    if (c[0]) c[0]->print();
    printf("[%.5lf %.5lf]", x, y), fflush(stdout);
    if (c[1]) c[1]->print();
  }
  void pr(void) { print(), puts(""), fflush(stdout); }
} pool[110000], *pos = pool;
int xi[110000];
double yi[110000], mins[110000];
int n, q, A, B;
inline ntp gnew(double x, double y) {
  pos++, pos->x = x, pos->y = y;
  return pos;
}
void solve(void) {
  rt = gnew(1.0, 2.0 * (1 - xi[1])), rt->sc(gnew(q, 2.0 * (q - xi[1])), 1);
  rt->sc(gnew(-1, -1E30), 0);
  for (int i = 2; i <= n; i++) {
    rt->get()->splay();
    double& p = mins[i - 1];
    ntp t, t2;
    if (fabs(rt->y) <= 1E-12) {
      rt->y = 0, p = rt->x;
      if (A != B) t = gnew(p, 0), t->sc(rt->c[1], 1), rt->sc(t, 1);
    } else {
      double X1 = rt->x, Y1 = rt->y, X2, Y2;
      rt->next(0)->splay(), X2 = rt->x, Y2 = rt->y;
      p = (X2 * Y1 - Y2 * X1) / (Y1 - Y2);
      if (A != B) {
        t = gnew(p, 0), t->sc(rt->c[1], 1), rt->sc(t, 1);
        t2 = gnew(p, 0), t2->sc(rt->c[1], 1), rt->sc(t2, 1), t2->splay();
      }
    }
    if (A != B)
      t->dx = B, t->push(), t->splay(), rt->c[0]->dx = A;
    else
      rt->dx = A;
    rt->k = 2, rt->b = -2.0 * xi[i];
  }
  rt->get()->splay();
  double ts;
  if (fabs(rt->y) <= 1E-12)
    ts = rt->x;
  else {
    double X1 = rt->x, Y1 = rt->y, X2, Y2;
    rt->next(0)->splay(), X2 = rt->x, Y2 = rt->y;
    ts = (X2 * Y1 - Y2 * X1) / (Y1 - Y2);
  }
  yi[n] = ts > q ? q : max(ts, (double)A * (n - 1) + 1);
  for (int i = n - 1; i >= 1; i--)
    yi[i] = yi[i + 1] < mins[i] + A   ? yi[i + 1] - A
            : yi[i + 1] > mins[i] + B ? yi[i + 1] - B
                                      : mins[i];
}
int main(void) {
  scanf("%d%d%d%d", &n, &q, &A, &B);
  for (int i = 1; i <= n; i++) scanf("%d", xi + i);
  solve();
  for (int i = 1; i <= n; i++) printf("%lf ", yi[i]);
  double ans = 0;
  for (int i = 1; i <= n; i++) ans += ((xi[i] - yi[i]) * (xi[i] - yi[i]));
  printf("\n%lf\n", ans);
  return 0;
}