const input = require('fs').readFileSync('/dev/stdin', 'utf8'); const [[N], S, T] = input.split('\n').map(v => v.split(/\s/)); for (i in S) { if (S[i] != T[i]) { console.log(`${Number(i) + 1}\n${S[i]}\n${T[i]}`); break; } }