#include <bits/stdc++.h>
using namespace std;
void File_input() {
  freopen("in.txt", "r", stdin);
  freopen("out.txt", "w", stdout);
}
void FastInputOutput() {
  ios_base ::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
}
vector<char> geno['z' + 1];
int t, n;
string str;
bool vis['z' + 1], in['z' + 1];
int indeg['z' + 1];
void DFS(char a) {
  cout << a;
  for (auto i : geno[a]) {
    if (!vis[i]) {
      vis[i] = 1;
      DFS(i);
    }
  }
}
int main() {
  cin >> t;
  while (t--) {
    cin >> str;
    n = (long long)str.size();
    for (int i = 0; i < n; i++) in[str[i]] = 1;
    for (int i = 1; i < n; i++) {
      geno[str[i - 1]].push_back(str[i]);
      indeg[str[i]]++;
    }
  }
  for (char a = 'a'; a <= 'z'; a++) {
    if (!vis[a] && in[a] && !indeg[a]) {
      DFS(a);
    }
  }
  return 0;
}
