#include <bits/stdc++.h>
using namespace std;
const int maxn = 100100;
struct SuffixArray {
  int s[maxn];
  int sa[maxn];
  int rk[maxn];
  int height[maxn];
  int t[maxn], t2[maxn], c[maxn];
  int n;
  void clear() { n = 0; }
  void build_sa(int m) {
    int i, *x = t, *y = t2;
    for (i = 0; i < m; i++) c[i] = 0;
    for (i = 0; i < n; i++) c[x[i] = s[i]]++;
    for (i = 1; i < m; i++) c[i] += c[i - 1];
    for (i = n - 1; i >= 0; i--) sa[--c[x[i]]] = i;
    for (int k = 1; k <= n; k <<= 1) {
      int p = 0;
      for (i = n - k; i < n; i++) y[p++] = i;
      for (i = 0; i < n; i++)
        if (sa[i] >= k) y[p++] = sa[i] - k;
      for (i = 0; i < m; i++) c[i] = 0;
      for (i = 0; i < n; i++) c[x[y[i]]]++;
      for (i = 0; i < m; i++) c[i] += c[i - 1];
      for (i = n - 1; i >= 0; i--) sa[--c[x[y[i]]]] = y[i];
      swap(x, y);
      p = 1;
      x[sa[0]] = 0;
      for (i = 1; i < n; i++)
        x[sa[i]] = y[sa[i - 1]] == y[sa[i]] && y[sa[i - 1] + k] == y[sa[i] + k]
                       ? p - 1
                       : p++;
      if (p >= n) break;
      m = p;
    }
  }
  void build_height() {
    int i, j, k = 0;
    for (i = 0; i < n; i++) rk[sa[i]] = i;
    for (i = 0; i < n - 1; i++) {
      if (k) k--;
      int j = sa[rk[i] - 1];
      while (s[i + k] == s[j + k]) k++;
      height[rk[i]] = k;
    }
  }
  void add(int ch) { s[n++] = ch; }
};
SuffixArray sa;
int flag[maxn];
int Log[maxn];
int lcp[maxn][20];
int callcp(int a, int b) {
  int tt = b - a + 1, len = Log[tt];
  return min(lcp[a][len], lcp[a + tt - (1 << len)][len]);
}
int cal(int l, int r) {
  if (l > r) swap(l, r);
  if (l == r) {
    return 0;
  }
  return callcp(l + 1, r);
}
char s[maxn];
int lens;
bool judge(int x) {
  for (int j = 0; j + x < lens; j += x) {
    int l = cal(sa.rk[j], sa.rk[j + x]), tmp = l / x, u = j - (x - l % x);
    if (l % x && u >= 0 && cal(sa.rk[u], sa.rk[u + x]) >= x) tmp++;
    if (tmp) return true;
  }
  return false;
}
char t[maxn];
int lent;
void renew(int x) {
  for (int i = 0; i < x; i++) {
    t[i] = s[i];
  }
  lent = x;
  for (int i = x, tmp = 0; i < lens; i++) {
    t[lent++] = s[i];
    if (s[i] == s[i - x])
      tmp++;
    else
      tmp = 0;
    if (tmp == x) {
      tmp = 0;
      lent -= x;
    }
  }
  for (int i = 0; i < lent; i++) {
    s[i] = t[i];
  }
  lens = lent;
  s[lens] = 0;
}
void update() {
  sa.clear();
  for (int j = 0; j < lens; j++) {
    sa.add(s[j] - 'a' + 1);
  }
  sa.add(0);
  sa.build_sa(27);
  sa.build_height();
  for (int i = 1; i < sa.n; i++) lcp[i][0] = sa.height[i];
  for (int j = 1; j <= Log[lens]; j++) {
    for (int i = 1; i + (1 << j) <= sa.n; i++) {
      lcp[i][j] = min(lcp[i][j - 1], lcp[i + (1 << (j - 1))][j - 1]);
    }
  }
}
int main() {
  Log[0] = -1;
  for (int i = 1; i < maxn; i++) {
    Log[i] = Log[i >> 1] + 1;
  }
  scanf("%s", s);
  lens = strlen(s);
  update();
  for (int i = 1; i * 2 <= lens; i++) {
    if (judge(i)) {
      renew(i);
      update();
    }
  }
  puts(s);
  return 0;
}
