__author__ = 'Vera'
fin = open('input.txt', 'r')
fout=open('output.txt', 'w')
reads=[]
for line in fin.readlines():
    reads.append(line.replace('\n',''))
k=len(reads[0])
fout.write(reads[0])
for r in reads[1:]:
    fout.write(r[k-1:])
fin.close()
fout.close()
