#include <bits/stdc++.h>
using namespace std;
char buf[1 << 21], *p1 = buf, *p2 = buf;
inline long long rd() {
  long long x = 0, f = 1;
  char ch =
      (p1 == p2 && (p2 = (p1 = buf) + fread(buf, 1, 1 << 21, stdin), p1 == p2)
           ? EOF
           : *p1++);
  while (!isdigit(ch)) {
    if (ch == '-') f = -1;
    ch =
        (p1 == p2 && (p2 = (p1 = buf) + fread(buf, 1, 1 << 21, stdin), p1 == p2)
             ? EOF
             : *p1++);
  }
  while (isdigit(ch))
    x = x * 10 + (ch ^ 48),
    ch =
        (p1 == p2 && (p2 = (p1 = buf) + fread(buf, 1, 1 << 21, stdin), p1 == p2)
             ? EOF
             : *p1++);
  return x * f;
}
const long long N = 100010;
long long n, p, a[N], now, ans[N];
priority_queue<pair<long long, long long> > q;
queue<long long> qu;
set<long long> s;
signed main() {
  n = rd(), p = rd();
  for (register long long i = 1; i <= n; ++i) q.push(make_pair(-rd(), -i));
  for (register long long i = 1; i <= n; ++i) {
    if (qu.empty() && s.empty()) now = -q.top().first;
    now += p;
    while (!q.empty() && -q.top().first <= now) {
      if (qu.empty() || -q.top().second < qu.back())
        qu.push(-q.top().second);
      else
        s.insert(-q.top().second);
      q.pop();
    }
    ans[qu.front()] = now, qu.pop();
    if (qu.empty() && !s.empty()) qu.push(*s.begin()), s.erase(s.begin());
  }
  for (register long long i = 1; i <= n; ++i) printf("%lld ", ans[i]);
  return 0;
}
