const main = (arg) => { const a = arg.trim().split("\n"); a.shift(); console.log(a.map(b=>{ const n = Number(b.match(/\d+/)[0]) + 1; return b.replace(/\d+/, n.toString()); }).join("\n")) }; main(require('fs').readFileSync('/dev/stdin', 'utf8'));