Main(require("fs").readFileSync("/dev/stdin", "utf8"));

function Main(input){
    var args = input.split('\n');
    var N = parseInt(args[0].split(' ')[0], 10);
    var S = [];

    for(var i=1; i<=N; i++){
        S.push(args[i]);
    }

    console.log( S.sort().join('') );
}