'use strict';
function diastring (str) {
  let res = "";
  str.split('¥n').forEach((l, i) => {
    res += l.charAt(i);
  });
  return res;
}

module.exports = diastring;

let input = "";
process.stdin.on('data', (chunk) => {
  input+=chunk;
});
process.stdin.on('end', () => {
  let result = diastring(input);
  console.log(result);
  console.log(input);
  process.stdout.write(result);
});