#include <bits/stdc++.h>
using namespace std;
vector<long long int> g[27];
bool v[27];
bool v1[27];
bool p[27];
void dfs(long long int x) {
  v[x] = 1;
  cout << char(x + 'a');
  for (auto it : g[x])
    if (!v[it]) dfs(it);
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  ;
  long long int n;
  string s;
  cin >> n;
  if (n == 1) {
    cin >> s;
    cout << s;
    return 0;
  }
  for (long long int i = 0; i < n; i++) {
    string s;
    cin >> s;
    if (s.length() == 1) v1[s[0] - 'a'] = 1;
    for (long long int i = 0; i < s.size() - 1; i++) {
      long long int ptr = s[i] - 'a';
      long long int nptr = s[i + 1] - 'a';
      g[ptr].push_back(nptr);
      p[nptr] = 1;
    }
  }
  for (long long int i = 0; i < 26; i++)
    if (!v[i] && !g[i].empty() && p[i] == 0) dfs(i);
  for (long long int i = 0; i < 26; i++)
    if (!v[i] && v1[i]) cout << char(i + 'a');
  return 0;
}
