function main (input) {
  const A = parseInt(input.split(' ')[0]);
  const B = parseInt(input.split(' ')[1]);
  const C = parseInt(input.split(' ')[2]);

  if (A === B) {
    console.log(C);
  } else if (B === C) {
    console.log(A);
  } else {
    console.log(B);
  }
}

main(require('fs').readFileSync('/dev/stdin', 'utf8'));