#include <bits/stdc++.h>
using namespace std;
const int max_n = 30;
int front[max_n];
int back[max_n];
bool show[max_n];
bool used[max_n];
char s[150];
void dfs(int i) {
  if (i == -1) return;
  used[i] = true;
  printf("%c", (char)i + 'a');
  dfs(back[i]);
}
int main() {
  int n;
  int len;
  scanf("%d", &n);
  memset(show, 0, sizeof(show));
  memset(used, 0, sizeof(used));
  memset(front, -1, sizeof(front));
  memset(back, -1, sizeof(back));
  for (int i = 0; i < n; ++i) {
    scanf("%s", s);
    len = strlen(s);
    for (int i = 0; i < len; ++i) {
      show[(int)s[i] - 'a'] = true;
      if (i > 0) front[(int)s[i] - 'a'] = (int)s[i - 1] - 'a';
      if (i < len - 1) back[(int)s[i] - 'a'] = (int)s[i + 1] - 'a';
    }
  }
  for (int i = 0; i < 26; ++i)
    if ((show[i]) && (!used[i]) && (front[i] == -1)) dfs(i);
  return 0;
}
