#include <bits/stdc++.h>
char sv[30];
int used[30];
int nxt[30];
int cnt[30];
int main() {
  int n;
  scanf("%d\n", &n);
  memset(nxt, -1, sizeof nxt);
  for (int i = 0; i < n; i++) {
    scanf("%s", sv);
    for (int j = 0; j < strlen(sv) - 1; j++) {
      nxt[sv[j] - 'a'] = sv[j + 1] - 'a';
      cnt[sv[j + 1] - 'a'] = 1;
    }
    for (int j = 0; j < strlen(sv); j++) used[sv[j] - 'a'] = 1;
  }
  for (int i = 0; i < 26; i++) {
    if (used[i] && cnt[i] != 1) {
      int cur = i;
      while (cur != -1) {
        used[cur] = 0;
        printf("%c", char('a' + cur));
        cur = nxt[cur];
      }
    }
  }
  puts("");
}
